I have developed an application that monitors events in the filesystem using the FileSystemWatcher
class and would like to leave it installed on the file server as it happens that I need to register the user who accessed the file over the network.
Note: locally I know I can use:
System.Security.Principal.WindowsIdentity.GetCurrent().Name
or
ManagementObjectSearcher searcher =
new ManagementObjectSearcher("SELECT UserName FROM Win32_ComputerSystem");
ManagementObjectCollection collection = searcher.Get();
and the network?