Share via


FILECHANGEINFO

A version of this page is also available for

Windows Embedded CE 6.0 R3

4/8/2010

This structure contains information about a file system event.

Syntax

struct _FILECHANGEINFO {
  DWORD cbSize;
  LONG wEventId;
  ULONG uFlags;
  DWORD dwItem1;
  DWORD dwItem2;
  DWORD dwAttributes;
  FILETIME ftModified;
  ULONG nFileSize;
} FILECHANGEINFO, *LPFILECHANGEINFO;

Members

  • cbSize
    Size of this structure.
  • wEventId
    Describes the event that has occurred. Typically, only one event is specified at a time. If more than one event is specified, the values contained in the dwItem1 and dwItem2 members must be the same for all specified events.

    The following table shows possible values. The member can be set to one or more of these values.

    Value Description

    SHCNE_ASSOCCHANGED

    Not supported.

    SHCNE_ATTRIBUTES

    The attributes of an item or folder have changed. SHCNF_PATH must be specified in the uFlags member. The dwItem1 member contains a pointer to a string array that stores the item or folder that has changed. The dwItem2 member is reserved and must be set to NULL.

    SHCNE_CREATE

    A non-folder item has been created. SHCNF_PATH must be specified in uFlags. The dwItem1 membercontains a pointer to a string array that stores the item that was created. The dwItem2 member is not used and must be set to NULL.

    SHCNE_DELETE

    A non-folder item has been deleted. SHCNF_PATH must be specified in uFlags. The dwItem1 member contains a pointer to a string array that stores the item that was deleted. The dwItem2 member is reserved and must be set to NULL.

    SHCNE_DRIVEADD

    A drive has been added. SHCNF_PATH must be specified in uFlags. The dwItem1 member contains a pointer to a string array that stores the root of the drive that was added. The dwItem2 member is reserved and must be set to NULL.

    SHCNE_DRIVEADDGUI

    A drive has been added, and the shell must create a new window for the drive. SHCNF_PATH must be specified in uFlags. The dwItem1 member contains a pointer to a string array that stores the root of the drive that was added. The dwItem2 member is reserved and must be set to NULL.

    SHCNE_DRIVEREMOVED

    A drive has been removed. SHCNF_PATH must be specified in uFlags. The dwItem1 member contains a pointer to a string array that stores the root of the drive that was removed. The dwItem2 member is reserved and must be set to NULL.

    SHCNE_MEDIAINSERTED

    Storage media has been inserted into a drive. SHCNF_PATH must be specified in uFlags. The dwItem1 member contains a pointer to a string array that stores the root of the drive that contains the new media. The dwItem2 member is reserved and must be set to NULL.

    SHCNE_MEDIAREMOVED

    Storage media has been removed from a drive. SHCNF_PATH must be specified in uFlags. The dwItem1 member contains a pointer to a string array that stores the root of the drive from which the media was removed. The dwItem2 member is reserved and must be set to NULL.

    SHCNE_MKDIR

    A folder has been created. SHCNF_PATH must be specified in uFlags. The dwItem1 member contains a pointer to a string array that stores the folder that was created. The dwItem2 member is reserved and must be set to NULL.

    SHCNE_NETSHARE

    A folder on the local computer is being shared through the network. SHCNF_PATH must be specified in uFlags. The dwItem1 member contains a pointer to a string array that stores the folder that is being shared. The dwItem2 member is reserved and must be set to NULL.

    A connection was made to a remote server.

    SHCNE_NETUNSHARE

    A folder on the local computer is no longer being shared through the network. SHCNF_PATH must be specified in uFlags. The dwItem1 member contains a pointer to a string array that stores the folder that is no longer being shared. The dwItem2 member is reserved and must be set to NULL.

    A connection to a server has been removed.

    SHCNE_RENAMEFOLDER

    The name of a folder has changed. SHCNF_PATH must be specified in uFlags. The dwItem1 member contains a pointer to a string array that stores the previous name of the folder. The dwItem2 member contains a pointer to a string array that stores the name of the folder.

    SHCNE_RENAMEITEM

    The name of a non-folder item has changed. SHCNF_PATH must be specified in uFlags. the dwItem1 member contains a pointer to a string array that stores the name of the item. The dwItem2 member contains a pointer to a string array that stores the new name of the item.

    SHCNE_RMDIR

    A folder has been removed. SHCNF_PATH must be specified in uFlags. The dwItem1 member contains a pointer to a string array that stores the folder that was removed. The dwItem2 member is reserved and must be set to NULL.

    SHCNE_SERVERDISCONNECT

    The computer has disconnected from a server. SHCNF_PATH must be specified in uFlags. The dwItem1 member contains a pointer to a string array that stores the server from which the computer was disconnected. The dwItem2 member is reserved and must be set to NULL.

    SHCNE_UPDATEDIR

    The contents of an existing folder have changed, but the folder still exists and has not been renamed. SHCNF_PATH must be specified in uFlags. The dwItem1 member contains a pointer to a string array that stores the folder that has changed. The dwItem2 member is reserved and must be set to NULL. If a folder has been created, deleted, or renamed, use SHCNE_MKDIR, SHCNE_RMDIR, or SHCNE_RENAMEFOLDER, instead.

    SHCNE_UPDATEIMAGE

    An image in the system image list has changed. SHCNF_DWORD must be specified in uFlags. The dwItem1 member contains the index in the system image list that has changed. The dwItem2 member is reserved and must be set to NULL.

    SHCNE_UPDATEITEM

    An existing non-folder item has changed, but the item still exists and has not been renamed. SHCNF_PATH must be specified in uFlags. The dwItem1 member contains a pointer to a string array that stores the item that has changed. The dwItem2 memberis reserved and must be set to NULL. If a non-folder item has been created, deleted, or renamed, use SHCNE_CREATE, SHCNE_DELETE, or SHCNE_RENAMEITEM, instead.

  • uFlags
    Flags that indicate the meaning of the dwItem1 and the dwItem2 members. The following table shows possible values.

    Value Description

    SHCNF_DWORD

    The dwItem1 and the dwItem2 members are DWORD values. This flag is currently not supported.

    SHCNF_IDLIST

    The dwItem1 and the dwItem2 members are the addresses of ITEMIDLIST structures that represent the item(s) affected by the change. Each ITEMIDLIST must be relative to the desktop folder. This flag is currently not supported.

    SHCNF_PATH

    The dwItem1 and the dwItem2 members are pointers to string arrays that contain the full path names of the items affected by the change.

    SHCNF_PRINTER

    The dwItem1 and the dwItem2 members are pointers to string arrays that represent the friendly names of the printers affected by the change. This flag is currently not supported.

    The following table shows flags that modify other data-type flags. These flags cannot be used without one of the previously described values.

    Value Description

    SHCNF_FLUSHNOWAIT

    The function should begin delivering notifications to all affected components but should return as soon as the notification process has begun. If this flag is not set, this function does not return until the notification has been delivered to all affected components.

  • dwItem1
    Notification-specific value that is dependent on the value of uFlags. If uFlags is SHCNF_PATH, the dwItem1 and the dwItem2 members are pointers to strings that contain the full paths of the item(s) affected by the change.
  • dwItem2
    Notification-specific value that is dependent on the value of uFlags. If uFlags is SHCNF_PATH dwItem1 and dwItem2 are pointers to strings that contain the full paths of the item(s) affected by the change.
  • dwAttributes
    Attributes of the file, folder, or item.
  • ftModified
    Time when the event occurred.
  • nFileSize
    Size of the file, folder, or item.

Requirements

Header extfile.h, shlobj.h
Library ceshell.lib
Windows Embedded CE Windows CE 2.10 and later
Windows Mobile Pocket PC 2002 and later, Smartphone 2002 and later

See Also

Reference

File I/O Structures

Other Resources

Shell Structures
SHCHANGENOTIFYENTRY