Listening for file change beneath a folder

G

Guest

If the following question is not the appropriate newsgroup, please direct me
to the appropriate newsgroup.

I'm working on an application that must listen for files being added,
modified, or removed from a specified folder; or one of it's subdirectories.
The application will respond by collecting information about the file(s) and
updating a database. Could someone suggest a good way to listen for these
events? I'd prefer using managed code, if possible, but I'm open to any
suggestions.
 
G

Guest

Hi,
FileSystemWatcher class comes in handy when we want to monitor a folder for
any changes made. Consider we are having a production server which needs to
be monitored and an email should be triggered when a unanticipated file
change is encountered. In these circumstance FileSystemWatcher can be used to
monitor files in the server.
Below links shows how to do same:
http://www.c-sharpcorner.com/Upload...atcher03192007133144PM/FileSystemWatcher.aspx
http://www.expresscomputeronline.com/20040531/techspace02.shtml
http://msdn2.microsoft.com/en-us/library/system.io.notifyfilters(VS.71).aspx
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top