I'm trying to aggregate all my Performance Counters into one UI, and I'm having a hard time with the PerformanceCounterCategory.GetCategories()
method. It keeps throwing Access Denied
, however I'm impersonating as the Administrator account on the remote machine.
I have a feeling that this call does not use the impersonated user's credentials, however, I can't seem to find any info on how to set the appropriate username/password.
ASP.NET MVC 2 C#.NET 4.0 Windows 7