[Now Supported on Windows NT]
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.
WINSHELLAPI void WINAPI SHChangeNotify(
LONG wEventId, | |
UINT uFlags, | |
LPCVOID dwItem1, | |
LPCVOID dwItem2 | |
); |
Parameters
wEventId
Array of flags that specifies the events. This parameter can be a combination of the following values:
SHCNE_ASSOCCHANGED | Changed a file type association. |
SHCNE_ATTRIBUTES | Changed a file's attributes. |
SHCNE_CREATE | Created a file. |
SHCNE_DELETE | Deleted a file. |
SHCNE_DRIVEADD | Added a network drive. |
SHCNE_DRIVEADDGUI | Added a network drive by way of a graphic user interface. |
SHCNE_DRIVEREMOVED | Removed a network drive. |
SHCNE_INTERRUPT | Performed the event as a result of a system interrupt. |
SHCNE_MEDIAINSERTED | Added removable media, such as a CD-ROM. |
SHCNE_MEDIAREMOVED | Removed a removable medium, such as a CD-ROM. |
SHCNE_MKDIR | Created a new directory. |
SHCNE_NETSHARE | Shared a resource on the network. |
SHCNE_NETUNSHARE | Stopped sharing a resource. |
SHCNE_RENAMEFOLDER | Renamed a folder. |
SHCNE_RENAMEITEM | Renamed an item in a folder. |
SHCNE_RMDIR | Removed a directory. |
SHCNE_SERVERDISCONNECT | Disconnected a network server. |
SHCNE_UPDATEDIR | Updated the contents of a directory. |
SHCNE_UPDATEIMAGE | Changed an image in the system global image list. |
SHCNE_UPDATEITEM | Changed the properties of a printer or file. |
uFlags
Flag that indicates the meaning of dwItem1 and dwItem2. This parameter can be one of the following values:
SHCNF_DWORD | The dwItem1 and dwItem2 parameters are doubleword values. |
SHCNF_FLUSH | Flushes the system event buffer. The function does not return until the system is finished processing the given event. |
SHCNF_FLUSHNOWAIT | Flushes the system event buffer. The function returns immediately regardless of whether the system is finished processing the given event. |
SHCNF_IDLIST | dwItem1 and dwItem2 are the addresses of item identifier lists. |
SHCNF_PATH | dwItem1 and dwItem2 are path names. |
SHCNF_PRINTER | dwItem1 and dwItem2 are printer "friendly" names. |
dwItem1
First event-dependent value.
dwItem2
Second event-dependent value.
Return Values
No return value.