The information in this article applies to:
SYMPTOMS
The following warnings are displayed when a debug version of a program is
executed and TRACE() diagnostics are enabled:
CAUSE
The above warnings are displayed by the CWnd::~CWnd() destructor.
The warnings indicate the following:
RESOLUTION
MFC Technote #17 contains more information on how to properly destroy a
Window object and states the following cardinal rule:
Also, examining CWnd::~CWnd() will reveal that the foremost task of the destructor is to ensure that the associated Windows window object has been destroyed. If a program calls DestroyWindow() before the CWnd destructor is called, the m_hWnd data member will be NULL, the TRACE0() messages will not occur, and DestroyWindow() will not be called in CWnd::~CWnd(). Additional query words:
Keywords : kbMFC kbVC kbWndw kbGrpMFCATL |
Last Reviewed: November 25, 1999 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |