解决 Warning: calling DestroyWindow in CWnd::~CWnd OnDestroy or PostNcDestroy in derived class will not
解决Warning:callingDestroyWindowinCWnd::~CWndOnDestroyorPostNcDestroyinderivedclasswillnotbecalled 出现上面Warning,原因是,调用窗口类析构的时候,窗口对象还没有销毁。具体表现在,当在一个窗口中生成另外一个窗口CTestDlg时: CTestDlg *pDlg = new CTestDl