Is it possible to use the FileSystemWatcher to find the PID or process name that is changing a file?
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
Nope, you need a file system filter driver to track changes with such details.
回答2:
Negative. The only information you will have is the data contained in the FileSystemEventArgs
class, documented here.
This means you only get the type of change that was made, as well as the path to the file that was changed.