Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Note
This method is deprecated. Instead we recommend that you use the SetPowerState property of the CIM_PowerManagementService class.
Sets the power state of the computer system.
This method is inherited from CIM_ComputerSystem.
Syntax
uint32 SetPowerState(
[in] uint32 PowerState,
[in] datetime Time
);
Parameters
-
PowerState [in]
-
The requested power state for the computer system.
This property can contain one of the following values:
-
1
-
Full Power
-
2
-
Power Save - Low Power Mode
-
3
-
Power Save - Standby
-
4
-
Power Save - Other
-
5
-
Power Cycle
-
6
-
Power Off
-
7
-
Hibernate
-
8
-
Soft Off
Time [in]
Indicates when to set the power state, either as a regular datetimevalue or as an interval value (where the interval begins when the method invocation is received).
Return value
A return code that indicates whether the operation completed successfully.
-
0
The operation completed successfully.
-
1
The operation was not completed because it is not supported.
-
2 ...
The operation was not completed because an error occurred.
Requirements
Minimum supported client |
Windows Vista |
Minimum supported server |
Windows Server 2008 |
Namespace |
Root\hardware |
MOF |
|
DLL |
|