9 out of 12 rated this helpful - Rate this topic

Shell Functions

This section describes the Windows Shell functions.

In this section

TopicDescription

Intsafe.h Functions

Library Functions

NeedCurrentDirectoryForExePath

TBD

PathAllocCanonicalize

TBD

PathAllocCombine

TBD

PathCchAddBackslash

TBD

PathCchAddBackslashEx

TBD

PathCchAddExtension

TBD

PathCchAppend

TBD

PathCchAppendEx

TBD

PathCchCanonicalize

TBD

PathCchCanonicalizeEx

TBD

PathCchCombine

TBD

PathCchCombineEx

TBD

PathCchFindExtension

TBD

PathCchIsRoot

TBD

PathCchRemoveBackslash

TBD

PathCchRemoveBackslashEx

TBD

PathCchRemoveExtension

TBD

PathCchRemoveFileSpec

TBD

PathCchRenameExtension

TBD

PathCchSkipRoot

TBD

PathCchStripPrefix

TBD

PathCchStripToRoot

TBD

PathIsUNCEx

TBD

AddMRUStringW

Adds a string to the top of the most recently used (MRU) list.

Note  This function is available through Windows XP with Service Pack 2 (SP2) and Windows Server 2003. It might be altered or unavailable in subsequent versions of Windows.

AssocCreateForClasses

Retrieves an object that implements an IQueryAssociations interface.

AssocGetDetailsOfPropKey

Retrieves the value for a given property key using the file association information provided by the Namespace Extensions.

CallCPLEntry16

Performs no function. Provided for backward compatibility.

Note  This function is available in Windows 2000 and through Windows XP Service Pack 2 (SP2). It is no longer available as of Windows Vista.

CanShareFolderW

Used to determine whether to show the Share this folder option in web view.

Note  This function is available through Windows XP with SP2 and Windows Server 2003. It might be altered or unavailable in subsequent versions of Windows.

CDefFolderMenu_Create2

Creates a context menu for a selected group of file folder objects.

CIDLData_CreateFromIDArray

CIDLData_CreateFromIDArray may be altered or unavailable.

CIShutdown

Shuts down the content indexer and closes all open catalogs.

CommandLineToArgvW

Parses a Unicode command line string and returns an array of pointers to the command line arguments, along with a count of such arguments, in a way that is similar to the standard C run-time argv and argc values.

CPlApplet

Serves as the entry point for a Control Panel application. This is a library-defined callback function.

CreateAppContainerProfile

Creates a per-user, per-app profile for Metro style apps.

CreateEnvironmentBlock

Retrieves the environment variables for the specified user. This block can then be passed to the CreateProcessAsUser function.

CreateHardwareEventMoniker

Creates a moniker representing a hardware component and its associated event handler. AutoPlay uses this function to allow applications to use AutoPlay events.

Note  This function is available through Windows XP with SP2 and Windows Server 2003. It might be altered or unavailable in subsequent versions of Windows.

CreateMRUListW

Creates a new MRU list.

CreateProfile

Creates a new user profile.

CreateUserProfileEx

Creates a user profile for a specified user.

Note  This function is not available as of Windows Vista.

CscSearchApiGetInterface

Creates an instance of a CCscSearchApiInterface object.

Warning  This function is deprecated and might be altered or unavailable in subsequent versions.

DAD_AutoScroll

Scrolls the window while an image is being dragged.

Note   DAD_AutoScroll is available in Windows 2000 and Windows XP. It might be altered or unavailable in subsequent versions.

DAD_DragEnterEx

Locks updates to the specified window during a drag operation and displays the drag image at the specified position within the window.

Note   DAD_DragEnterEx is available in Windows 2000 and Windows XP. It might be altered or unavailable in subsequent versions. Use ImageList_DragEnter instead.

DAD_DragEnterEx2

Locks updates to the specified window during a drag-and-drop operation and displays the drag image at the specified position within the window.

Note   DAD_DragEnterEx2 is available in Windows 2000 and Windows XP. It might be altered or unavailable in subsequent versions. Use ImageList_DragEnter instead.

DAD_DragLeave

Unlocks the window locked by the DAD_DragEnterEx function.

Note   DAD_DragLeave is available in Windows 2000 and Windows XP. It might be altered or unavailable in subsequent versions. Use ImageList_DragLeave instead.

DAD_DragMove

Moves the image that is being dragged during a drag-and-drop operation.

Note   DAD_DragMove is available in Windows 2000 and Windows XP. It might be altered or unavailable in subsequent versions. Use ImageList_DragMove instead.

DAD_SetDragImage

Sets the drag image.

Note   DAD_SetDragImage is available in Windows 2000 and Windows XP. It might be altered or unavailable in subsequent versions. Use ImageList_BeginDrag instead.

DAD_ShowDragImage

Shows or hides the image being dragged.

Note   DAD_ShowDragImage is available in Windows 2000 and Windows XP. It might be altered or unavailable in subsequent versions. Use ImageList_DragShowNolock instead.

DefScreenSaverProc

Provides default processing for any messages that a screen saver application does not process.

DefSubclassProc

Calls the next handler in a window's subclass chain. The last handler in the subclass chain calls the original window procedure for the window.

DeleteAppContainerProfile

Deletes the specified per-user, per-app profile.

DeleteProfile

Deletes the user profile and all user-related settings from the specified computer. The caller must have administrative privileges to delete a user's profile.

DestroyEnvironmentBlock

Frees environment variables created by the CreateEnvironmentBlock function.

DeriveAppContainerSidFromAppContainerName

Gets the SID of the specified profile.

DllGetVersion

Implemented by many of the Windows Shell DLLs to allow applications to obtain DLL-specific version information.

DoEnvironmentSubst

Parses an input string that contains references to one or more environment variables and replaces them with their fully expanded values.

Note  This function is retained only for backward compatibility. Use ExpandEnvironmentStrings instead.

DragAcceptFiles

Registers whether a window accepts dropped files.

DragFinish

Releases memory that the system allocated for use in transferring file names to the application.

DragQueryFile

Retrieves the names of dropped files that result from a successful drag-and-drop operation.

DragQueryPoint

Retrieves the position of the mouse pointer at the time a file was dropped during a drag-and-drop operation.

DriveType

DriveType may be altered or unavailable.

DuplicateIcon

Creates a duplicate of a specified icon.

EnumMRUListW

Enumerates the contents of the MRU list. Optionally retrieves an item from the enumeration.

Note  This function is available through Windows XP with SP2 and Windows Server 2003. It might be altered or unavailable in subsequent versions of Windows.

EstimateFileRiskLevel

Estimates the risk of executing unknown code when a handler is called on a given file. This risk is based on an understanding of the handler and the code content of the file.

Note  This function is available on Windows XP with SP2 through Windows Vista. It might be altered or unavailable in subsequent versions of Windows. Client applications instead should use IAttachmentExecute to present a user environment that provides safe download and exchange of files through email and messaging attachments.

ExpandEnvironmentStringsForUser

Expands the source string by using the environment block established for the specified user.

ExtractAssociatedIcon

Gets a handle to an icon stored as a resource in a file or an icon stored in a file's associated executable file.

ExtractAssociatedIconEx

ExtractAssociatedIconEx may be altered or unavailable.

ExtractIcon

Gets a handle to an icon from the specified executable file, DLL, or icon file.

To retrieve an array of handles to large or small icons, use the ExtractIconEx function.

ExtractIconEx

The ExtractIconEx function creates an array of handles to large or small icons extracted from the specified executable file, DLL, or icon file.

FileIconInit

Initializes or reinitializes the system image list.

FindExecutable

Retrieves the name of and handle to the executable (.exe) file associated with a specific document file.

FreeConfirmConflictItem

Frees the resources that have been allocated for a CONFIRM_CONFLICT_ITEM structure.

FreeIDListArray

Frees the memory used by an pointer to an item identifier list (PIDL) list array.

FreeIDListArrayChild

Releases the memory space for the array of pointers to child item IDs. This releases both the PITEMID_CHILDs within the array and the array itself.

FreeIDListArrayFull

Releases the memory space for the PIDL array. This releases both the PIDLIST_ABSOLUTEs within the array and the array itself.

FreeKnownFolderDefinitionFields

Frees the allocated fields in the result from IKnownFolder::GetFolderDefinition.

FreeMRUList

Frees the handle associated with the MRU list and writes cached data to the registry.

GetAllUsersProfileDirectory

Retrieves the path to the root of the directory that contains program data shared by all users.

GetAppContainerFolderPath

Gets the local folder for the specified profile.

GetAppContainerRegistryLocation

Gets the location of the registry storage for the current profile.

GetCurrentProcessExplicitAppUserModelID

Retrieves the application-defined, explicit Application User Model ID (AppUserModelID) for the current process.

GetDefaultUserProfileDirectory

Retrieves the path to the root of the default user's profile.

GetFileNameFromBrowse

Creates an Open dialog box so that the user can specify the drive, directory, and name of a file to open.

Note  This function is available through Windows XP SP2 and Windows Server 2003. It might be altered or unavailable in subsequent versions of Windows.

GetMenuContextHelpId

Retrieves the Help context identifier associated with the specified menu.

GetProfilesDirectory

Retrieves the path to the root directory where user profiles are stored.

GetProfileType

Retrieves the type of profile loaded for the current user.

GetScaleFactorForDevice

Gets the preferred scale factor for a primary or for an immersive type of display device.

GetUserProfileDirectory

Retrieves the path to the root directory of the specified user's profile.

GetWindowContextHelpId

Retrieves the Help context identifier, if any, associated with the specified window.

GetWindowSubclass

Retrieves the reference data for the specified window subclass callback.

GUIDFromString

Converts a string to a GUID.

Note   GUIDFromString is available through Windows XP with SP2 or Windows Vista. It might be altered or unavailable in subsequent versions. Applications should use CLSIDFromString or IIDFromString in place of this function.

IDListContainerIsConsistent

Verifies that the container structure of an IDList is valid.

ILAppendID

Appends or prepends an SHITEMID structure to an ITEMIDLIST structure.

ILClone

Clones an ITEMIDLIST structure.

ILCloneChild

Clones a child ITEMIDLIST structure.

ILCloneFirst

Clones the first SHITEMID structure in an ITEMIDLIST structure.

ILCloneFull

Clones a full, or absolute, ITEMIDLIST structure.

ILCombine

Combines two ITEMIDLIST structures.

ILCreateFromPath

Returns the ITEMIDLIST structure associated with a specified file path.

ILFindChild

Determines whether a specified ITEMIDLIST structure is the child of another ITEMIDLIST structure.

ILFindLastID

Returns a pointer to the last SHITEMID structure in an ITEMIDLIST structure.

ILFree

Frees an ITEMIDLIST structure allocated by the Shell.

ILGetNext

Retrieves the next SHITEMID structure in an ITEMIDLIST structure.

ILGetSize

Returns the size, in bytes, of an ITEMIDLIST structure.

ILIsAligned

Verifies whether a constant ITEMIDLIST is aligned on a pointer boundary, which is a DWORD on 32-bit architectures and a QWORD on 64-bit architectures.

ILIsChild

Verifies whether a PIDL is a child PIDL, which is a PIDL with exactly one SHITEMID.

ILIsEmpty

Verifies whether an ITEMIDLIST structure is empty.

ILIsEqual

Tests whether two ITEMIDLIST structures are equal in a binary comparison.

ILIsParent

Tests whether an ITEMIDLIST structure is the parent of another ITEMIDLIST structure.

ILLoadFromStream

Deprecated. Loads an ITEMIDLIST structure from a stream.

Note  This function is available through Windows XP SP2 and Windows Server 2003. It might be altered or unavailable in subsequent versions of Windows.

ILLoadFromStreamEx(IStream*, PIDLIST_ABSOLUTE*)

This function may be altered or unavailable.

ILLoadFromStreamEx(IStream*, PIDLIST_RELATIVE*)

This function may be altered or unavailable.

ILLoadFromStreamEx(IStream*, PITEMID_CHILD*)

This function may be altered or unavailable.

ILNext(PCUIDLIST_RELATIVE)

Retrieves the next SHITEMID structure in an ITEMIDLIST structure.

ILNext(PUIDLIST_RELATIVE)

Retrieves the next SHITEMID structure in an ITEMIDLIST structure.

ILRemoveLastID

Removes the last SHITEMID structure from an ITEMIDLIST structure.

ILSaveToStream

Saves an ITEMIDLIST structure to a stream.

ILSkip(PCUIDLIST_RELATIVE, UINT)

Skips a given number of bytes in a constant, unaligned, relative ITEMIDLIST structure.

ILSkip(PUIDLIST_RELATIVE, UINT)

Skips a given number of bytes in an unaligned, relative ITEMIDLIST structure.

InetIsOffline

Determines whether the system is connected to the Internet.

InitNetworkAddressControl

Initializes the network address control window class.

InitVariantFromGUIDAsString

Initializes a VARIANT structure based on a GUID. The structure is initialized as VT_BSTR.

IsNetDrive

Tests whether a drive is a network drive.

Note  This function is available through Windows XP SP2 and Windows Server 2003. It might be altered or unavailable in subsequent versions of Windows. Use GetDriveType or WNetGetConnection instead.

IsUserAnAdmin

IsUserAnAdmin may be altered or unavailable.

LinkWindow_RegisterClass

Registers a window class that allows for the SysLink common control to be used in a window.

Note  This function is available through Windows XP with SP2 and Windows Server 2003. It might be altered or unavailable in subsequent versions of Windows. Use InitCommonControlsEx instead.

LinkWindow_UnregisterClass

Unregisters a window class registered by LinkWindow_RegisterClass.

Note  This function is available through Windows XP with SP2 and Windows Server 2003. It might be altered or unavailable in subsequent versions of Windows.

LoadUserProfile

Loads the specified user's profile. The profile can be a local user profile or a roaming user profile.

MIMEAssociationDialog

Runs the unregistered MIME content type dialog box.

Note  Windows XP Service Pack 2 (SP2) or later: This function is no longer supported.

OpenRegStream

OpenRegStream may be altered or unavailable. Instead, use SHOpenRegStream2 or SHOpenRegStream.

ParseField

Reads a line from Setup.inf and extracts the specified field from the string.

Note  The ParseField function is currently expected to be available for use in the next version of the Microsoft Windows operating system. It might be altered or unavailable in subsequent versions.

PassportWizardRunDll

Launches the Passport Wizard when used with Rundll32.exe.

Note  This function is available through Windows XP with SP2 and Windows Server 2003. It might be altered or unavailable in subsequent versions of Windows.

PathCleanupSpec

PathCleanupSpec may be altered or unavailable.

PathGetShortPath

PathGetShortPath may be altered or unavailable.

PathIsExe

PathIsExe may be altered or unavailable.

PathIsSlow

PathIsSlow may be altered or unavailable.

PathMakeUniqueName

Creates a unique path name from a template.

PathProcessCommand

Deprecated. Processes a string that contains a command line and generates a suitably quoted string, with arguments attached if required.

PathResolve

PathResolve may be altered or unavailable.

PathYetAnotherMakeUniqueName

Creates a unique filename based on an existing filename.

PerUserInit

Creates My Documents and other special folders, initializes them as needed, and creates the Send To shortcut menu item for My Documents.

Note  This function is available through Windows XP with SP2 and Windows Server 2003. It might be altered or unavailable in subsequent versions of Windows.

PickIconDlg

PickIconDlg may be altered or unavailable.

ReadCabinetState

ReadCabinetState may be altered or unavailable.

RealDriveType

RealDriveType may be altered or unavailable.

RegisterDialogClasses

Registers any nonstandard window classes required by a screen saver's configuration dialog box.

RegisterScaleChangeNotifications

Registers a window to receive callbacks when scaling information changes.

RemoveWindowSubclass

Removes a subclass callback from a window.

RestartDialog

Displays a dialog box that prompts the user to restart Windows. When the user clicks the button, the function calls ExitWindowsEx to attempt to restart Windows.

Note  This function is available through Windows XP SP2 and Windows Server 2003. It might be altered or unavailable in subsequent versions of Windows.

RestartDialogEx

Displays a dialog box that asks the user to restart Windows. When the user clicks the button, the function calls ExitWindowsEx to attempt to restart Windows.

Note  This function is available through Windows XP SP2 and Windows Server 2003. It might be altered or unavailable in subsequent versions of Windows.

RevokeScaleChangeNotifications

Revokes the registration of a window, preventing it from receiving callbacks when scaling information changes.

ScreenSaverConfigureDialog

Receives messages sent to a screen saver's configuration dialog box. A screen saver that allows user configuration must define this function.

ScreenSaverProc

Receives messages sent to the specified screen saver window.

SetCurrentProcessExplicitAppUserModelID

Specifies a unique application-defined AppUserModelID that identifies the current process to the taskbar. This identifier allows an application to group its associated processes and windows under a single taskbar button.

SetMenuContextHelpId

Associates a Help context identifier with a menu.

SetWindowContextHelpId

Associates a Help context identifier with the specified window.

SetWindowSubclass

Installs or updates a window subclass callback.

SHAddFromPropSheetExtArray

Adds pages to a property sheet extension array created by SHCreatePropSheetExtArray.

Note  This function is available through Windows XP SP2 and Windows Server 2003. It might be altered or unavailable in subsequent versions of Windows.

SHAddToRecentDocs

Notifies the system that an item has been accessed, for the purposes of tracking those items used most recently and most frequently. This function can also be used to clear all usage data.

SHAlloc

Note  This function is available through Windows XP SP2 and Windows Server 2003. It might be altered or unavailable in subsequent versions of Windows. Use CoTaskMemAlloc instead.

Allocates memory from the Shell's heap.

SHAllocShared

SHAllocShared may be altered or unavailable.

SHAppBarMessage

Sends an appbar message to the system.

SHAssocEnumHandlers

Returns an enumeration object for a specified set of file name extension handlers.

SHAssocEnumHandlersForProtocolByApplication

Gets an enumeration interface that provides access to handlers associated with a given protocol.

SHBindToFolderIDListParent

Given a Shell namespace item specified in the form of a folder, and an item identifier list relative to that folder, this function binds to the parent of the namespace item and optionally returns a pointer to the final component of the item identifier list.

SHBindToFolderIDListParentEx

Extends the SHBindToFolderIDListParent function by allowing the caller to specify a bind context.

SHBindToObject

Retrieves and binds to a specified object by using the Shell namespace IShellFolder::BindToObject method.

SHBindToParent

Takes a pointer to a fully qualified item identifier list (PIDL), and returns a specified interface pointer on the parent object.

SHBrowseForFolder

Displays a dialog box that enables the user to select a Shell folder.

SHChangeNotification_Lock

Locks the shared memory associated with a Shell change notification event.

SHChangeNotification_Unlock

Unlocks shared memory for a change notification.

SHChangeNotify

Notifies the system of an event that an application has performed. An application should use this function if it performs an action that may affect the Shell.

SHChangeNotifyDeregister

Unregisters the client's window process from receiving SHChangeNotify messages.

SHChangeNotifyRegister

Registers a window to receive notifications from the file system or Shell.

SHChangeNotifyRegisterThread

Enables asynchronous register and deregister of a thread.

SHCloneSpecialIDList

SHCloneSpecialIDList may be altered or unavailable. Instead, use SHGetSpecialFolderLocation.

SHCLSIDFromString

Takes the string form of a class identifier (CLSID) and creates the corresponding CLSID.

Note  This function is available through Windows XP SP2 and Windows Server 2003. It might be altered or unavailable in subsequent versions of Windows. Use CLSIDFromString instead.

SHCoCreateInstance

SHCoCreateInstance may be altered or unavailable. Instead, use CoCreateInstance.

SHCreateAssociationRegistration

Creates an IApplicationAssociationRegistration object based on the stock implementation of the interface provided by Windows.

SHCreateDataObject

Creates a data object in a parent folder.

SHCreateDefaultContextMenu

Creates an object that represents the Shell's default context menu implementation.

SHCreateDefaultExtractIcon

Creates a standard icon extractor, whose defaults can be further configured via the IDefaultExtractIconInit interface.

SHCreateDefaultPropertiesOp

Creates a file operation that sets the default properties on the Shell item that have not already been set.

SHCreateDirectory

Creates a new file system folder.

SHCreateDirectoryEx

Creates a new file system folder, with optional security attributes.

SHCreateFileExtractIcon

SHCreateFileExtractIcon may be altered or unavailable.

SHCreateItemFromIDList

Creates and initializes a Shell item object from a PIDL. The resulting shell item object supports the IShellItem interface.

SHCreateItemFromParsingName

Creates and initializes a Shell item object from a parsing name.

SHCreateItemFromRelativeName

Creates and initializes a Shell item object from a relative parsing name.

SHCreateItemInKnownFolder

Creates a Shell item object for a single file that exists inside a known folder.

SHCreateItemWithParent

Create a Shell item, given a parent folder and a child item ID.

SHCreateProcessAsUserW

Creates a new user-mode process and its primary thread to run a specified executable file.

Note  SHCreateProcessAsUserW is not implemented under Windows XP or later systems.

SHCreatePropSheetExtArray

SHCreatePropSheetExtArray may be altered or unavailable.

SHCreateQueryCancelAutoPlayMoniker

Deprecated. Creates a QueryCancelAutoPlay class moniker, which can then be used to register the IQueryCancelAutoPlay handler in the running object table (ROT).

Note  This function is deprecated. Use CreateClassMoniker instead. Note that the CLSID used in the call to CreateClassMoniker must be application-defined. Do not call CreateClassMoniker with a system-defined CLSID.

SHCreateShellFolderView

Creates a new instance of the default Shell folder view object (DefView).

SHCreateShellFolderViewEx

Creates a new instance of the default Shell folder view object. It is recommended that you use SHCreateShellFolderView rather than this function.

SHCreateShellItem

Creates an IShellItem object.

Note  It is recommended that you use SHCreateItemWithParent or SHCreateItemFromIDList instead of this function.

SHCreateShellItemArray

Creates a Shell item array object.

SHCreateShellItemArrayFromDataObject

Creates a Shell item array object from a data object.

SHCreateShellItemArrayFromIDLists

Creates a Shell item array object from a list of ITEMIDLIST structures.

SHCreateShellItemArrayFromShellItem

Creates an array of one element from a single Shell item.

SHCreateStdEnumFmtEtc

SHCreateStdEnumFmtEtc may be altered or unavailable.

SHDefExtractIcon

Provides a default handler to extract an icon from a file.

SHDestroyPropSheetExtArray

SHDestroyPropSheetExtArray may be altered or unavailable.

SHDoDragDrop

Executes a drag-and-drop operation. Supports drag source creation on demand, as well as drag images.

Shell_GetCachedImageIndex

Shell_GetCachedImageIndex may be altered or unavailable.

Shell_GetImageLists

Retrieves system image lists for large and small icons.

Note  This function is available through Windows XP SP2 and Windows Server 2003. It might be altered or unavailable in subsequent versions of Windows.

Shell_MergeMenus

Shell_MergeMenus may be altered or unavailable.

Shell_NotifyIcon

Sends a message to the taskbar's status area.

Shell_NotifyIconGetRect

Gets the screen coordinates of the bounding rectangle of a notification icon.

ShellAbout

Displays a ShellAbout dialog box.

ShellDDEInit

Registers the Shell Dynamic Data Exchange (DDE) services in the current process, notifying the system that the current process wishes to host DDE objects.

ShellExecute

Performs an operation on a specified file.

ShellExecuteEx

Performs an operation on a specified file.

ShellMessageBox

ShellMessageBox may be altered or unavailable.

SHEmptyRecycleBin

Empties the Recycle Bin on the specified drive.

SHEnumerateUnreadMailAccounts

Enumerates the user accounts that have unread email.

SHEvaluateSystemCommandTemplate

Enforces strict validation of parameters used in a call to CreateProcess or ShellExecute.

SHExtractIconsW

Creates an array of handles to icons extracted from a specified file.

Note   SHExtractIconsW is available through Windows XP SP2. It might be altered or unavailable in subsequent versions.

SHFileOperation

Copies, moves, renames, or deletes a file system object. This function has been replaced in Windows Vista by IFileOperation.

SHFind_InitMenuPopup

SHFind_InitMenuPopup may be altered or unavailable.

SHFindFiles

SHFindFiles may be altered or unavailable.

SHFlushClipboard

Carries out the clipboard shutdown sequence. It also releases the IDataObject pointer placed on the clipboard by the OleSetClipboard function.

Note  This function is available through Windows XP SP2 and Windows Server 2003. It is not supported under Windows Vista and later. Use OleFlushClipboard instead.

SHFlushSFCache

SHFlushSFCache may be altered or unavailable.

SHFormatDrive

SHFormatDrive may be altered or unavailable.

SHFree

Frees the memory allocated by SHAlloc.

Note  This function is available through Windows XP SP2 and Windows Server 2003. It might be altered or unavailable in subsequent versions of Windows. Use CoTaskMemFree instead.

SHFreeNameMappings

Frees a file name mapping object that was retrieved by the SHFileOperation function.

SHFreeShared

SHFreeShared may be altered or unavailable.

SHGetAttributesFromDataObject

SHGetAttributesFromDataObject may be altered or unavailable.

SHGetDataFromIDList

Retrieves extended property data from a relative identifier list.

SHGetDesktopFolder

Retrieves the IShellFolder interface for the desktop folder, which is the root of the Shell's namespace.

SHGetDiskFreeSpace

Retrieves disk space information for a disk volume.

SHGetDiskFreeSpaceEx

Retrieves disk space information for a disk volume.

SHGetDriveMedia

Returns the type of media that is in the given drive.

SHGetFileInfo

Retrieves information about an object in the file system, such as a file, folder, directory, or drive root.

SHGetFolderLocation

Deprecated. Retrieves the path of a folder as an ITEMIDLIST structure.

SHGetFolderPath

Deprecated. Gets the path of a folder identified by a CSIDL value.

Note  As of Windows Vista, this function is merely a wrapper for SHGetKnownFolderPath. The CSIDL value is translated to its associated KNOWNFOLDERID and then SHGetKnownFolderPath is called. New applications should use the known folder system rather than the older CSIDL system, which is supported only for backward compatibility.

SHGetFolderPathAndSubDir

Gets the path of a folder and appends a user-provided subfolder path.

SHGetIconOverlayIndex

Returns the index of the overlay icon in the system image list.

SHGetIDListFromObject

Retrieves the PIDL of an object.

SHGetImageList

Retrieves an image list.

SHGetInstanceExplorer

Retrieves an interface that allows hosted Shell extensions and other components to prevent their host process from closing prematurely. The host process is typically Windows Explorer or Windows Internet Explorer, but this function can also be used by other applications.

SHGetItemFromDataObject

Creates an IShellItem or related object based on an item specified by an IDataObject.

SHGetItemFromObject

Retrieves an IShellItem for an object.

SHGetKnownFolderIDList

Retrieves the path of a known folder as an ITEMIDLIST structure.

SHGetKnownFolderItem

Retrieves an IShellItem object that represents a known folder.

SHGetKnownFolderPath

Retrieves the full path of a known folder identified by the folder's KNOWNFOLDERID.

SHGetLocalizedName

Retrieves the localized name of a file in a Shell folder.

SHGetMalloc

Retrieves a pointer to the Shell's IMalloc interface.

Note  SHGetMalloc is available through Windows Vista and Windows Server 2003, but may be altered or unavailable in subsequent versions of the operating system or product. See the Remarks section for alternate recommendations.

SHGetNameFromIDList

Retrieves the display name of an item identified by its IDList.

SHGetNameFromPropertyKey

Retrieves the property's canonical name given its PROPERTYKEY.

SHGetNewLinkInfo

Creates a name for a new shortcut based on the shortcut's proposed target. This function does not create the shortcut, just the name.

SHGetPathFromIDList

Converts an item identifier list to a file system path.

SHGetPathFromIDListEx

Converts an item identifier list to a file system path. This function extends SHGetPathFromIDList by allowing you to set the initial size of the string buffer and declare the options below.

SHGetRealIDL

SHGetRealIDL may be altered or unavailable.

SHGetSetFolderCustomSettings

SHGetSetFolderCustomSettings may be altered or unavailable.

SHGetSetSettings

SHGetSetSettings may be altered or unavailable.

SHGetSettings

Retrieves the current Shell option settings.

SHGetShellStyleHInstance

Deprecated. Attempts to get a handle to the Shellstyle.dll file.

Note  SHGetShellStyleHInstance is available for use in the Windows XP operating system up to and including SP2. It is not available in later versions of Windows, such as Windows Vista.

SHGetSpecialFolderLocation

SHGetSpecialFolderLocation is not supported and may be altered or unavailable in the future. Instead, use SHGetFolderLocation.

SHGetSpecialFolderPath

SHGetSpecialFolderPath is not supported. Instead, use ShGetFolderPath.

SHGetStockIconInfo

Retrieves information about system-defined Shell icons.

SHGetTemporaryPropertyForItem

Retrieves the temporary property for the given item. A temporary property is a read/write store that holds properties only for the lifetime of the IShellItem object, rather than being persisted back into the item.

SHGetUnreadMailCount

Retrieves a specified user's unread message count for any or all email accounts.

SHGetViewStatePropertyBag

SHGetViewStatePropertyBag may be altered or unavailable.

SHHandleUpdateImage

SHHandleUpdateImage may be altered or unavailable.

SHILCreateFromPath

SHILCreateFromPath may be altered or unavailable.

SHInvokePrinterCommand

Executes a command on a printer object.

Note  This function has been deprecated as of Windows Vista. It is recommended that, in its place, you invoke verbs on printers through IContextMenu or ShellExecute.

SHIsFileAvailableOffline

Determines whether a file or folder is available for offline use. This function also determines whether the file would be opened from the network, from the local Offline Files cache, or from both locations.

SHLimitInputEdit

Sets limits on valid characters for an edit control.

Note  This function is available through Windows XP SP2 and Windows Server 2003. It might be altered or unavailable in subsequent versions of Windows.

SHLoadInProc

Creates an instance of the specified object class from within the context of the Shell's process.

Windows Vista and later: This function has been disabled and returns E_NOTIMPL.

SHLoadNonloadedIconOverlayIdentifiers

Signals the Shell that during the next operation requiring overlay information, it should load icon overlay identifiers that either failed creation or were not present for creation at startup. Identifiers that have already been loaded are not affected.

SHLoadOLE

Deprecated. Provided for backward compatibility.

Note  This function is available through Windows XP SP2 and Windows Server 2003. It is not supported as of Windows Vista.

SHLocalStrDup

Makes a copy of a string in newly allocated memory.

SHLockShared

SHLockShared may be altered or unavailable.

SHMapIDListToImageListIndexAsync

Retrieves an index in the system image list when given an IShellFolder and an ITEMIDLIST that is contained in it. This function also gets the final icon from the callback if necessary.

Note  This function is available through Windows XP SP2 and Windows Server 2003. It is not available as of Windows Vista.

SHMapPIDLToSystemImageListIndex

SHMapPIDLToSystemImageListIndex may be altered or unavailable.

SHMultiFileProperties

Displays a merged property sheet for a set of files. Property values common to all the files are shown while those that differ display the string (multiple values).

SHObjectProperties

SHObjectProperties may be altered or unavailable.

SHOpenFolderAndSelectItems

Opens a Windows Explorer window with specified items in a particular folder selected.

SHOpenPropSheet

SHOpenPropSheet may be altered or unavailable.

SHOpenWithDialog

Displays the Open With dialog box.

ShowShareFolderUI

Displays the Folder Sharing tab on the properties sheet for the specified folder.

SHParseDisplayName

Translates a Shell namespace object's display name into an item identifier list and returns the attributes of the object. This function is the preferred method to convert a string to a PIDL.

SHPathPrepareForWrite

Checks to see if the path exists. This includes remounting mapped network drives, prompting for ejectable media to be reinserted, creating the paths, prompting for the media to be formatted, and providing the appropriate user interfaces, if necessary. Read/write permissions for the medium are not checked.

SHQueryRecycleBin

Retrieves the size of the Recycle Bin and the number of items in it, for a specified drive.

SHQueryUserNotificationState

Checks the state of the computer for the current user to determine whether sending a notification is appropriate.

SHRegGetBoolValueFromHKCUHKLM

Evaluates a registry key value and returns a boolean value that reflects whether the value exists and the expected state matches the actual state. This function will first check HKEY_CURRENT_USER for the requested information in the specified subkey. If the information does not exist under the HKEY_CURRENT_USER subtree it will check the HKEY_LOCAL_MACHINE subtree for the same information.

Note  This function is no longer supported.

SHRegGetValueFromHKCUHKLM

Obtains specified information from the registry. This function will check HKEY_CURRENT_USER for the requested information in the specified subkey. If the information does not exist under the HKEY_CURRENT_USER subtree, the function checks the HKEY_LOCAL_MACHINE subtree for the same information.

Note  This function is no longer supported.

SHRemoveLocalizedName

Removes the localized name of a file in a Shell folder.

SHReplaceFromPropSheetExtArray

Requests each property sheet in a property sheet extension array to replace pages. Each page is allowed up to one replacement.

Note  This function is available through Windows XP SP2 and Windows Server 2003. It might be altered or unavailable in subsequent versions of Windows.

SHRestricted

SHRestricted may be altered or unavailable.

SHRunControlPanel

Opens a Control Panel item.

Note  This function is not supported as of Windows Vista

SHSetDefaultProperties

Applies the default set of properties on a Shell item.

SHSetFolderPath

Deprecated. Assigns a new path to a system folder identified by its CSIDL.

SHSetInstanceExplorer

Provides an interface that allows hosted Shell extensions and other components to prevent their host process from closing prematurely. The host process is typically Windows Explorer or Internet Explorer, but this function can also be used by other applications.

SHSetKnownFolderPath

Redirects a known folder to a new location.

SHSetLocalizedName

Sets the localized name of a file in a Shell folder.

SHSetTemporaryPropertyForItem

Sets a temporary property for the specified item. A temporary property is kept in a read/write store that holds properties only for the lifetime of the IShellItem object, instead of writing them back into the item.

SHSetUnreadMailCount

Stores the current user's unread message count for a specified email account in the registry.

SHShellFolderView_Message

SHShellFolderView_Message may be altered or unavailable.

SHSimpleIDListFromPath

Deprecated. Returns a pointer to an ITEMIDLIST structure when passed a path.

SHStartNetConnectionDialog

SHStartNetConnectionDialog may be altered or unavailable.

SHTestTokenMembership

Uses CheckTokenMembership to test whether the given token is a member of the local group with the specified RID.

SHUnlockShared

SHUnlockShared may be altered or unavailable.

SHUpdateImage

Notifies the Shell that an image in the system image list has changed.

SHValidateUNC

SHValidateUNC may be altered or unavailable.

SignalFileOpen

SignalFileOpen may be altered or unavailable.

SoftwareUpdateMessageBox

Displays a standard message box that can be used to notify a user that an application has been updated.

StgMakeUniqueName

Creates a unique name for a stream or storage object from a template.

StrStrNIW

Finds the first occurrence of a substring within a string. The comparison is case-insensitive.

StrStrNW

Finds the first occurrence of a substring within a string. The comparison is case-sensitive.

TranslateURL

Applies common translations to a given URL string, creating a new URL string.

UnloadUserProfile

Unloads a user's profile that was loaded by the LoadUserProfile function. The caller must have administrative privileges on the computer. For more information, see the Remarks section of the LoadUserProfile function.

UpdateAllDesktopSubscriptions

Deprecated. Enumerates the URLs of all the Desktop components and then tests to see if they are subscribed to. If they are subscribed to, the subscriptions are delivered.

URLAssociationDialog

Invokes the unregistered URL protocol dialog box. This dialog box allows the user to select an application to associate with a previously unknown protocol.

Note  Windows XP SP2 or later: This function is no longer supported.

Win32DeleteFile

Win32DeleteFile may be altered or unavailable.

WinExecError

Retrieves the error value generated if the WinExec function cannot run a specified application.

Note  This function is no longer implemented.

WinHelp

Launches Windows Help (Winhelp.exe) and passes additional data that indicates the nature of the help requested by the application.

WOWShellExecute

Performs an operation on a specified file. WOWShellExecute exists only for use with the Microsoft Windows NT Virtual DOS Machine (Ntvdm.exe), which allows disk operating system (DOS) and 16-bit software to run on a Windows system, and should not be used by anyone else. Use ShellExecute instead.

Note  This function is available through Windows XP with SP2 and Windows Server 2003. It might be altered or unavailable in subsequent versions of Windows.

WriteCabinetState

WriteCabinetState may be altered or unavailable.

 

 

 

Send comments about this topic to Microsoft

Build date: 3/7/2012

Did you find this helpful?
(1500 characters remaining)
Community Content Add
Annotations FAQ