Why FileSystemWatcher Multiple Change Events are occuring and how to overcome that?
I googled, but nothing was working good.
Loading
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Posted Oct 18, 2010, 8:28 AM
fsw.NotifyFilter = NotifyFilters.LastWrite;
fsw.Path = @"\\SystemName\FilePath\";
fsw.Changed += new FileSystemEventHandler(fsw_Changed);
fsw.Filter = "*.txt";
fsw.EnableRaisingEvents = true;
Jean PaulPosted Oct 18, 2010, 7:22 AM
Additional filtering can be done using property 'IncludeSubdirectories' to false.