Important: |
---|
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist. |
This function creates a change notification handle and sets up initial change notification filter conditions. A wait on a notification handle succeeds when a change matching the filter conditions occurs in the specified registry key or subkeys.
Syntax
HANDLE CeFindFirstRegChange ( HKEY hKey, BOOL bWatchSubtree, DWORD dwNotifyFilter ); |
Parameters
- hKey
-
[in] Handle to an open key. This handle is returned by the RegCreateKeyExor the RegOpenKeyExfunction, or it can be set to one of the following predefined keys:
-
HKEY_CLASSES_ROOT
-
HKEY_CURRENT_CONFIG
-
HKEY_CURRENT_USER
-
HKEY_LOCAL_MACHINE
-
HKEY_USERS
-
HKEY_CLASSES_ROOT
- bWatchSubtree
-
[in] If this parameter is set to TRUE, the function reports changes in the specified key and its subkeys. If the parameter is set to FALSE, the function reports changes only in the specified key.
- dwNotifyFilter
-
[in] Changes to be reported. This following table shows possible values.
Value Description REG_NOTIFY_CHANGE_LAST_SET
Notify the caller of changes to a value of the key. This can include adding or deleting a value or changing an existing value.
REG_NOTIFY_CHANGE_NAME
Notify the caller if a subkey is added or deleted.
Return Value
A handle to a find change notification object indicates success. INVALID_HANDLE_VALUE indicates failure. To get extended error information, call GetLastError.
Requirements
Header | winreg.h |
Library | coredll.lib |
Windows Embedded CE | Windows CE 5.0 and later |
Windows Mobile | Windows Mobile Version 5.0 and later |
See Also
Reference
Registry Notification FunctionsRegCreateKeyEx
RegOpenKeyEx