7.6. Change Functions

The 32-bit APIs supports a facility called change notification, which allows an application to detect changes in files and directories. (See Section 4.7 for a description of the facility and its uses.)

The change notification facility uses change handles to notify the program of changes. A change handle is initially un-signaled but changes to signaled when the appropriate directory is modified. You use the Wait functions (Section 7.4) in your code to detect when a change handle signals.

Listing 7.18 demonstrates change handles. When you run this program, it will display a line that indicates that it is waiting. If you use the File Manager or a second DOS shell to rename a file in c:\, then the program will indicate that ...

Get Win32 System Services: The Heart of Windows® 98 and Windows® 2000 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.