
Displaying window while a dialog box function operates
Quote:
> I have an MFC app that displays a dialog box with several buttons to
> perform functions that can take several minutes to complete. When a
> button is selected I want to pop up a simple window to tell the user
> "This may take a minute", and continue with the function, then
> terminate
> the window, never giving the user the ability to kill the window or go
> back to the underlaying dialog box.
You need to derive a dialog from CDialog, let's call it CWarningDlg,
then when a button is selected, you need to create a modeless dialog
box, something like this:
CWarningDlg* pWarningDlg = new CWarningDlg( this );
pWarningDlg->Create(this);
When the function finishes, you need to destroy the modeless dialog
box:
pWarningDlg->DestroyWindow();
Hope this help, I myself am having a hard time with these modeless
dialog boxes, but I think I can help you with this problem. Let me know
if you need more help.
Juana
Quote: