PlatformMapPowerStateHint (Windows CE 5.0)

Send Feedback

This function maps the system power state hint values to known system power states maintained in the system registry.

DWORD WINAPI PlatformMapPowerStateHint(DWORD dwHint,  LPSTR pszBuf,  DWORD dwBufChars);

Parameters

  • dwHint
    Hint flag associated with the system power state.
  • pszBuf
    Mapped system power state name.
  • dwBufChars
    Number of characters in pszBuf.

Return Values

  • ERROR_SUCCESS
    This function was successful.
  • Win32 error code
    All other errors.

Remarks

An application can invoke system power state transitions without using explicit state names. For example, SetSystemPowerState(NULL, POWER_STATE_SUSPEND, 0) directs the Power Manager to transition the system into the appropriate suspend system power state. When unnamed state transitions are requested in this fashion, the MDD calls PlatformMapPowerStateHint to receive the name of the most appropriate system power state. For example, POWER_STATE_SUSPEND may map to a system power state named Suspend. Or in a more complex system, it may map to SuspendBattery or SuspendAC, depending on whether the system currently runs on battery or AC power.

Requirements

OS Versions: Windows CE .NET 4.0 and later.
Header: Pmimpl.h.
Link Library: Coredll.lib.

See Also

Power Management

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.