BOOL ExitWindows(dwReserved,wReturnCode)
This function initiates the standard Windows shutdown procedure. If all applications agree to terminate, the Windows session is terminated and control returns to DOS. Windows sends the WM_QUERYENDSESSION message to notify all applications that a request has been made to terminate Windows. If all applications agree to terminate, Windows sends the WM_ENDSESSION message to all applications before exiting.
Parameter | Type/Description |
dwReserved | DWORD Is reserved and should be set to zero. | |
wReturnCode | WORD Specifies the return value to be passed to DOS when Windows exits. |
The return value is FALSE if one or more applications refused to terminate. The function does not return if all applications agree to be terminated.