Hello everybody and sorry if i duplicate question(my english so bad). Is there any way to be notified when files are opened by a user? Something like the FileSystemWatcher class, except with an "Opened" event? I just want detect opening file without changed or renamed this file. for example, now i detect renaming file and want detecting opening too
private void hookEvents(String path, String password)
{
FileSystemWatcher fsw = new FileSystemWatcher();
fsw.Path = Path.GetDirectoryName(path);
fsw.Filter = Path.GetFileName(path);
fsw.Renamed += new RenamedEventHandler(onRenamed);
fsw.EnableRaisingEvents = true;
}
P.S. i hear some about filters and drivers, but i hope that c# have simple way for my request.