void PostQuitMessage(nExitCode)
This function informs Windows that the application wishes to terminate execution. It is typically used in response to a WM_DESTROY message.
The PostQuitMessage function posts a WM_QUIT message to the application and returns immediately; the function merely informs the system that the application wants to quit sometime in the future.
When the application receives the WM_QUIT message, it should exit the message loop in the main function and return control to Windows. The exit code returned to Windows must be the wParam parameter of the WM_QUIT message.
Parameter | Type/Description |
nExitCode | int Specifies an application exit code. It is used as the wParam parameter of the WM_QUIT message. |
None.