API Reference
Class
GroupPolicy
Helpers to query local/remote Group Policy service state and last refresh time.
Inheritance
- Object
- GroupPolicy
Methods
public static Nullable<DateTime> GetLastRefreshTime(String computerName = null) #Returns:
Nullable<DateTime>Attempts to determine the last Group Policy refresh timestamp for a computer.
Parameters
- computerName System.String = null
- Target computer; null/empty uses local machine.
Returns
Timestamp from event log when available; falls back to registry.
public static Boolean IsGpsvcRunning(String computerName = null) #Returns:
BooleanReturns true if the Group Policy Client service (gpsvc) is running on the specified or local computer.
Parameters
- computerName System.String = null
- Target computer; null/empty uses local machine.
Inherited Methods
public override Boolean Equals(Object obj) #Returns:
BooleanInherited from Object
Parameters
- obj Object