ServiceController[] lFnGetServicesInServer(string lStrServer) { try { ServiceController[] lArrObjServiceController = null; System.Security.Principal.WindowsImpersonationContext impersonationContext = null; impersonationContext = ((System.Security.Principal.WindowsIdentity)User.Identity).Impersonate(); lArrObjServiceController = ServiceController.GetServices(lStrServer.Trim()); return lArrObjServiceController; } catch (Exception ex) { throw ex; } } #endregion }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)