1

I have a filesystemwatcher event which watches the path. The problem is when a bulk of files are downloaded into the path where the filesystemwatcher watches, filecreated occurs first then filedeleted occurs which causes all the file to get delete and never the filecreated occur again.

I want to know how to control this condition of filesystemwatcher handling events for files which are getting downloading. I want only one event filecreated/filechanged after the file is finished downloading. And not any other events when it is downloading.

How to achieve this?

3
  • 1
    +1 (even with bad reputation) because i have the same problem with Log2Console that somtimes suddenly stops beeing informed by filesystemwatcher. I have to reboot the machine to get it working again. I am interested why .. Commented Jan 3, 2011 at 7:58
  • 2
    The type of file system events and how they are pushed is ultimately depending upon the application that does the job. For example, if you edit a .txt file with Notepad of Microsoft Word the events that will be generated are completely different. Some applications just delete and recreate files from scratch, other will change files inplace, etc... Commented Jan 3, 2011 at 8:54
  • @Simon: that should be THE answer :) Commented Jan 3, 2011 at 8:56

1 Answer 1

1

Why don't you tell what exactly you want to do may be a simple console app scheduled to run every few minutes will solve your problem.

Sign up to request clarification or add additional context in comments.

2 Comments

i didnt get any proper answers :(
I am not a big fan of file system listener..you should really try to change your approach to solving the problem.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.