shellapi.h header

This header is used by multiple technologies. For more information, see:

shellapi.h contains the following programming interfaces:

Functions

 
AssocCreateForClasses

Retrieves an object that implements an IQueryAssociations interface.
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.
DoEnvironmentSubstA

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

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

Registers whether a window accepts dropped files.
DragFinish

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

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

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.
DuplicateIcon

Creates a duplicate of a specified icon.
ExtractAssociatedIconA

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

ExtractAssociatedIconEx may be altered or unavailable.
ExtractAssociatedIconExW

ExtractAssociatedIconEx may be altered or unavailable.
ExtractAssociatedIconW

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

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.
ExtractIconExA

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

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

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.
FindExecutableA

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

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

Initializes the network address control window class.
NetAddr_DisplayErrorTip

Displays an error message in the balloon tip associated with the network address control.
NetAddr_GetAddress

Indicates whether a network address conforms to a specified type and format.
NetAddr_GetAllowType

Retrieves the network address types that a specified network address control accepts.
NetAddr_SetAllowType

Sets the network address types that a specified network address control accepts.
SHAppBarMessage

Sends an appbar message to the system.
SHCreateProcessAsUserW

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

Sends a message to the taskbar's status area.
Shell_NotifyIconGetRect

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

Sends a message to the taskbar's status area.
ShellAboutA

Displays a ShellAbout dialog box.
ShellAboutW

Displays a ShellAbout dialog box.
ShellExecuteA

Performs an operation on a specified file.
ShellExecuteExA

Performs an operation on a specified file.
ShellExecuteExW

Performs an operation on a specified file.
ShellExecuteW

Performs an operation on a specified file.
ShellMessageBoxA

ShellMessageBox may be altered or unavailable.
ShellMessageBoxW

ShellMessageBox may be altered or unavailable.
SHEmptyRecycleBinA

Empties the Recycle Bin on the specified drive.
SHEmptyRecycleBinW

Empties the Recycle Bin on the specified drive.
SHEnumerateUnreadMailAccountsA

Enumerates the user accounts that have unread email.
SHEnumerateUnreadMailAccountsW

Enumerates the user accounts that have unread email.
SHEvaluateSystemCommandTemplate

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

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

Copies, moves, renames, or deletes a file system object. On Windows Vista and later releases, we recommend that you use IFileOperation instead of this function.
SHFreeNameMappings

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

Retrieves disk space information for a disk volume.
SHGetDiskFreeSpaceExW

Retrieves disk space information for a disk volume.
SHGetDriveMedia

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

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

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

Retrieves an image list.
SHGetLocalizedName

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

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

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

Retrieves an object that represents a specific window's collection of properties, which allows those properties to be queried or set.
SHGetStockIconInfo

Retrieves information about system-defined Shell icons.
SHGetUnreadMailCountA

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

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

Executes a command on a printer object.
SHInvokePrinterCommandW

Executes a command on a printer object.
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.
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.
SHQueryRecycleBinA

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

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.
SHRemoveLocalizedName

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

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

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

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

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

Structures

 
APPBARDATA

Contains information about a system appbar message.
ASSOCIATIONELEMENT

Defines information used by AssocCreateForClasses to retrieve an IQueryAssociations interface for a given file association.
NC_ADDRESS

Contains information that describes a network address.
NOTIFYICONDATAA

Contains information that the system needs to display notifications in the notification area. Used by Shell_NotifyIcon.
NOTIFYICONDATAW

Contains information that the system needs to display notifications in the notification area. Used by Shell_NotifyIcon.
NOTIFYICONIDENTIFIER

Contains information used by Shell_NotifyIconGetRect to identify the icon for which to retrieve the bounding rectangle.
OPEN_PRINTER_PROPS_INFOA

Identifies a particular property sheet in a printer's property pages and whether that property sheet should be modal. Optionally used with the SHInvokePrinterCommand function.
OPEN_PRINTER_PROPS_INFOW

Identifies a particular property sheet in a printer's property pages and whether that property sheet should be modal. Optionally used with the SHInvokePrinterCommand function.
SHCREATEPROCESSINFOW

Contains the information needed by SHCreateProcessAsUserW to create a process.
SHELLEXECUTEINFOA

Contains information used by ShellExecuteEx.
SHELLEXECUTEINFOW

Contains information used by ShellExecuteEx.
SHFILEINFOA

Contains information about a file object.
SHFILEINFOW

Contains information about a file object.
SHFILEOPSTRUCTA

Contains information that the SHFileOperation function uses to perform file operations.
SHFILEOPSTRUCTW

Contains information that the SHFileOperation function uses to perform file operations.
SHNAMEMAPPINGA

Contains the old and new path names for each file that was moved, copied, or renamed by the SHFileOperation function.
SHNAMEMAPPINGW

Contains the old and new path names for each file that was moved, copied, or renamed by the SHFileOperation function.
SHQUERYRBINFO

Contains the size and item count information retrieved by the SHQueryRecycleBin function.
SHSTOCKICONINFO

Receives information used to retrieve a stock Shell icon. This structure is used in a call SHGetStockIconInfo.

Enumerations

 
QUERY_USER_NOTIFICATION_STATE

Specifies the state of the machine for the current user in relation to the propriety of sending a notification. Used by SHQueryUserNotificationState.
SHSTOCKICONID

Used by SHGetStockIconInfo to identify which stock system icon to retrieve.