FileSystemWatcher is a .NET component class that listens to the file system change notifications and raises events when a directory, or file in a directory, changes.
The System.IO.FileSystemWatcher component class can be used in .NET applications to watch for changes in a specified directory. You can watch for changes in files and subdirectories of the specified directory. These changes can be observed on a local computer, a network drive, or a remote computer.
The Filter property can be set with a string value indicating which files and/or directories are to be watched for changes.