Linked by Rodney Holiman on Tue 15th Jun 2004 19:19 UTC
General Development There are times when a directory needs watched.  For reasons of its own, a program may need to know when a file is deleted, updated or renamed.  If .NET is involved, this is a trivial task.  Create an instance of the FileSystemWatcher; set some properties, and the task is completed.  If a non .NET solution is required (and regardless of the hype, some people haven't embraced .NET in all of its glory.), the ReadDirectoryChangesW function must be used, however the documentation for ReadDirectoryChangesW is sketchy at best.
Permalink for comment
To read all comments associated with this story, please click here.
ReadDirectoryChangesW
by Brad Clarke on Wed 16th Jun 2004 04:15 UTC

"If a non .NET solution is required the ReadDirectoryChangesW function must be used"

That statement is false.

There are other Win 32 API calls that can accomplish the same thing (FindFirstChangeNotification).

Francois Piette wrote a Delphi component 7 years ago that accomplishes the same thing.