PowerSettingAccessCheckEx function
Queries for a group policy override for specified power settings and specifies the requested access for the setting.
Syntax
DWORD WINAPI PowerSettingAccessCheckEx(
_In_ POWER_DATA_ACCESSOR AccessFlags,
_In_opt_ const GUID *PowerGuid,
_In_ REGSAM AccessType
);
Parameters
- AccessFlags [in]
-
The type of access to check for group policy overrides.
- PowerGuid [in, optional]
-
The identifier of the power setting.
- AccessType [in]
-
The type of security access for the setting. For more information, see Registry Key Security and Access Rights.
This parameter can be one of the following values.
Return value
Returns ERROR_SUCCESS (zero) if the call was successful, and a nonzero value if the call failed.
| Return code/value | Description |
|---|---|
|
The specified power setting is not currently overridden by a group policy. |
|
This program is blocked by group policy. For more information, contact your system administrator. |
|
Only Administrators can remotely access power settings. |
Requirements
|
Minimum supported client |
Windows 7 [desktop apps only] |
|---|---|
|
Minimum supported server |
Windows Server 2008 R2 [desktop apps only] |
|
Header |
|
|
Library |
|
|
DLL |
|