modal/modeless WTL dialog - ERROR - Object deleted before window wasdestroyed
i have a WTL app with a CMessageLoop, there's a big modal dialog that
is the app.
at some point this modal dialog spawns a modeless dialog
(CAxDialogImpl) which lives
for a few seconds and then wants to destroy itself from an internal
in the modeless dialog.
no matter how i try to destroy this modeless dialog, i get this
assertion that m_hWnd
was not set to NULL.
both the modal and modeless dialogs are also COM objects. the modal
dialog is created
as a CComObjectStackEx and the modeless dialog which refuses to die
nicely is created
CComObject<CTestDlg>* test = NULL;
HRESULT hr = CComObject<CTestDlg>::CreateInstance(&test);