S
Seko
Hi!
This is my first post here, so please excuse me for any mistakes I make.
---------------------
I'm having a hard time displaying modal/non-modal dialog boxes in a Windows
Forms Application project, because of the following problem:
If building a project in debug mode, I get a Debug Assertion when doing a
myDialog.DoModal() call, seemingly because a valid parent window handle for
the dialog cannot be found.
I've debugged the application, and found that a call to
AfxGetResourceHandle() triggers the assertion.
When building the same project with debugging disabled (in Release mode), no
exceptions are thrown, and the application runs flawlessly.
This is how I use the dialog (which has a class added, and extends from
CDialog):
CMyDialog theDialog;
theDialog.DoModal();
I've tried this too: CMyDialog theDialog(AfxGetMainWnd());
, but the error is the same.
(I'm using Visual C++ .NET 2003 Standard)
Any help would GREATLY be appreciated!
Thank you in advance,
-David
This is my first post here, so please excuse me for any mistakes I make.
---------------------
I'm having a hard time displaying modal/non-modal dialog boxes in a Windows
Forms Application project, because of the following problem:
If building a project in debug mode, I get a Debug Assertion when doing a
myDialog.DoModal() call, seemingly because a valid parent window handle for
the dialog cannot be found.
I've debugged the application, and found that a call to
AfxGetResourceHandle() triggers the assertion.
When building the same project with debugging disabled (in Release mode), no
exceptions are thrown, and the application runs flawlessly.
This is how I use the dialog (which has a class added, and extends from
CDialog):
CMyDialog theDialog;
theDialog.DoModal();
I've tried this too: CMyDialog theDialog(AfxGetMainWnd());
, but the error is the same.
(I'm using Visual C++ .NET 2003 Standard)
Any help would GREATLY be appreciated!
Thank you in advance,
-David