首页  编辑  

关机的消息

Tags: /超级猛料/Message.消息和事件/   Date Created:

]、。·ˉˇ¨〃々—~‖…’”〕〉》」』〗】∶!"'),.:;?]` 关机的消息是:WM_QUERYENDSESSION

WM_QUERYENDSESSION

nSource = (UINT) wParam;    // source of end-session request

fLogOff = lParam            // logoff flag

Parameters

nSource

Reserved for future use.

fLogOff

Value of lParam. Indicates whether the user is logging off or shutting down the system. Supported values include: ENDSESSION_LOGOFF.

Return Values

If an application can terminate conveniently, it should return TRUE; otherwise, it should return FALSE.  

当执行exitwindows函数时

它会发送一个WM_QUERYENDSESSION消息给所有正在运行的程序。