This method retrieves a pointer to the active main window of the application, instead of directly referring to the m_pMainWnd data member of the application object, if your application is an ActiveX server. For user-interface threads, this is equivalent to directly referring to the m_pActiveWnd data member of your application object.
If your application is not an ActiveX server, then calling this method is equivalent to directly referring to the m_pMainWnd data member of your application object.
Header file: | Afxwin.h |
Platforms: | H/PC 2.0, Palm-size PC, H/PC Pro |
Windows CE versions: | 1.0 and later |
Complete documentation: | Visual C++ documentation |
virtual CWnd * GetMainWnd( );