This member function is called by the version of WinMain that the framework provides. Override InitApplication to implement one-time initialization such as Windows class registration.
The InitApplication member function is obsolete in MFC. Any initialization that you would have done in InitApplication should be moved to InitInstance. If you override InitApplication, and do not call the base class function, you will leak the CDocTemplate objects that were added through CWinApp::AddDocTemplate.
virtual BOOL InitApplication( );
Header File | Afxwin.h |
Platforms | |
Versions | 1.0 and later |
Complete documentation | Visual C++ documentation |
CWinApp Overview, CWinApp Member Functions, Application Architecture Classes, CWinApp::InitInstance