RegisterPowerSettingNotification(this->m_hWnd,&GUID_BATTERY_PERCENTAGE_REMAINING,DEVICE_NOTIFY_WINDOW_HANDLE);
//注册
RegisterPowerSettingNotification(this->m_hWnd,&GUID_ACDC_POWER_SOURCE,DEVICE_NOTIFY_WINDOW_HANDLE);
UINT CDlg::OnPowerBroadcast(UINT nPowerEvent, UINT nEventData)
{
if(nPowerEvent==PBT_POWERSETTINGCHANGE)
{
AfxMess