Expand Minimize
This topic has not yet been rated - Rate this topic

CWinApp::Run

Provides a default message loop.

virtual int Run( );

Return Value

An int value that is returned by WinMain.

Remarks

Run acquires and dispatches Windows messages until the application receives a WM_QUIT message. If the application's message queue currently contains no messages, Run calls OnIdle to perform idle-time processing. Incoming messages go to the PreTranslateMessage member function for special processing and then to the Windows function TranslateMessage for standard keyboard translation; finally, the DispatchMessage Windows function is called.

Run is rarely overridden, but you can override it to provide special behavior.

See Also

CWinApp Overview | Class Members | Hierarchy Chart | CWinApp::PreTranslateMessage | WM_QUIT | DispatchMessage | TranslateMessage

Did you find this helpful?
(1500 characters remaining)
© 2013 Microsoft. All rights reserved.