Partager via


PlatformSetSystemPowerState (Compact 2013)

3/26/2014

This function reads and verifies the system power state information from the registry and updates all devices appropriately.

Syntax

DWORD WINAPI PlatformSetSystemPowerState(
  LPCSTSTR pszName,
  BOOL fForce,
  BOOL fInternal
);

Parameters

  • pszName
    System power state name.
  • fForce
    Force flag.
  • fInternal
    Internal flag.

Return Value

  • ERROR_SUCCESS
    Indicates success.
  • Win32 error code
    Used for all other errors.

Remarks

This function always updates all device power states to be consistent with the pszName parameter. Power Manager may carry out other tasks as well, depending on the system power state. For example, suspending the system or sending messages to applications.**In addition, Power Manager may carry out platform-specific tasks associated with the system power state transition.

Requirements

Header

pmimpl.h

See Also

Reference

Power Management Functions