This documentation is archived and is not being maintained.


The framework calls this member function whenever the handler does not catch an exception thrown in one of your thread's message or command handlers.

virtual LRESULT ProcessWndProcException(
   CException *e,
   const MSG *pMsg 


Points to an unhandled exception.
Points to a MSG structure containing information about the windows message that caused the framework to throw an exception.

Return Value

–1 if a WM_CREATE exception is generated; otherwise 0.


Do not call this member function directly.

The default implementation of this member function handles only exceptions generated from the following messages:

Command Action
WM_PAINT Validate the affected window, thus preventing another WM_PAINT message from being generated.

Override this member function to provide global handling of your exceptions. Call the base functionality only if you wish to display the default behavior.

This member function is used only in threads that have a message pump.

See Also

CWinThread Overview | Class Members | Hierarchy Chart | CWinApp::ProcessWndProcException