Registering for Power Events

Applications can better adapt their behavior to the current power state of the computer by registering for power events. An application should register for each power change event that might impact its behavior.

An application or service uses the RegisterPowerSettingNotification function to register for notifications. When the corresponding power setting changes, the system sends notifications as follows:

In the POWERBROADCAST_SETTING structure, the PowerSetting member contains the GUID that identifies the notification and the Data member contains the new value of the power setting.

For a list of power setting GUIDs for notifications that are most useful to applications, see Power Setting GUIDs.