This topic has not yet been rated - Rate this topic

CWinThread::m_pActiveWnd

Use this data member to store a pointer to your thread's active window object.

CWnd* m_pActiveWnd;

Remarks

The Microsoft Foundation Class Library will automatically terminate your thread when the window referred to by m_pActiveWnd is closed. If this thread is the primary thread for an application, the application will also be terminated. If this data member is NULL, the active window for the application's CWinApp object will be inherited. m_pActiveWnd is a public variable of type CWnd*.

Typically, you set this member variable when you override InitInstance. In a worker thread, the value of this data member is inherited from its parent thread.

See Also

CWinThread Overview | Class Members | Hierarchy Chart | CWinThread::InitInstance | CWinThread::m_pMainWnd

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