access denied

How to Get Elevated Process Path in .Net

Process.MainModule.FileName throws for elevated processes. Here is how to get the process path in .NET with QueryFullProcessImageName instead.

Bugs in System.Diagnostics.Process Class

Process.StartTime and Process.HasExited throw an access denied Win32Exception for elevated processes. Here is why it happens and how to work around it.