Destroying ModalDialog
-
I'm opening a Modal Dialog inside a Modal Dialog. While destroying the second Dialog, application crashes at the following assert condition:
ASSERT(::IsWindow(m_hWnd))
in the file afxwin2.inl. How to destroy a Modal Dialog which is popped up inside another modal Dialog?
-
I'm opening a Modal Dialog inside a Modal Dialog. While destroying the second Dialog, application crashes at the following assert condition:
ASSERT(::IsWindow(m_hWnd))
in the file afxwin2.inl. How to destroy a Modal Dialog which is popped up inside another modal Dialog?
pix_programmer wrote:
How to destroy a Modal Dialog which is popped up inside another modal Dialog?
It typically "destroys" itself by the user clicking the OK or Cancel button, or pressing the Esc key.
"One man's wage rise is another man's price increase." - Harold Wilson
"Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons
"Some people are making such thorough preparation for rainy days that they aren't enjoying today's sunshine." - William Feather
-
I'm opening a Modal Dialog inside a Modal Dialog. While destroying the second Dialog, application crashes at the following assert condition:
ASSERT(::IsWindow(m_hWnd))
in the file afxwin2.inl. How to destroy a Modal Dialog which is popped up inside another modal Dialog?
This ASSERT is telling you the window doesn't exist anymore, like it was already suggested, modal dialogs don't typically get manually destroyed (although they can be).
-
I'm opening a Modal Dialog inside a Modal Dialog. While destroying the second Dialog, application crashes at the following assert condition:
ASSERT(::IsWindow(m_hWnd))
in the file afxwin2.inl. How to destroy a Modal Dialog which is popped up inside another modal Dialog?
Call EndDialog() method to have the second dialog destroyed properly.
onwards and upwards...