Re: Status Dialog Question?
Brad,
Try creating a dialog resource with a text control. Write a member function of your dialog class to set the text of that control, say SetStatus(). Then:
void MyFunction()
{
CMyDialog dlg;
dlg.DoModal();
dlg.SetStatus("Entering foo1");
foo1();
dlg.SetStatus("Entering foo2");
foo2();
.
.
.
}
If you want to call SetStatus from within foo1 and foo2, you can pass a pointer to your dialog into those functions.
I hope that helps.
Lane
Re: Status Dialog Question?
You need to create a Modeless Dialog box. Use the Create function to create it. Call whatever functions you want. Then when you are through with it call dlg.OnClose() to destroy it. Make sure you override PostNcDestroy and call "delete this" to freee the memory.
If you need any more details let me know.
Re: Status Dialog Question?
Sorry, but I omitted three components to my reply:
1. Hide any and all buttons in your dialog. Don't delete the OK button, just make it not visible.
2. Override CDialog::OnOK() and make it public. Have it call the base class function.
3. At the end of your function in which you create the dialog and call its DoModal function, call its OnOK function.
Re: Status Dialog Question?
I must be brain dead. Please ignore my posts and use a modeless dialog as Wayne Fuller suggested.
Sorry for any confusion I may have caused you.
Lane