how to hide "main dialog" properly?
-
The MFC app is "dialog based", "main window" is a CPropertySheet with 2 pages. logic process in CWinApp::InitInstance() looks like //------------------------------- Hide "main window" if(error) { show "main window"; display error on main dialog; } exit the app; //----------------------------- i have to hide main window first for some reasons - hard to explain why in a few sentences. according to process above, if no error, i should see nothing. but actually i always see the dialog in a flash. it means main window (property sheet) has not been hidden properly and thoroughly. do you know how to hide the dialog without seeing a flash? thx includeh10
-
The MFC app is "dialog based", "main window" is a CPropertySheet with 2 pages. logic process in CWinApp::InitInstance() looks like //------------------------------- Hide "main window" if(error) { show "main window"; display error on main dialog; } exit the app; //----------------------------- i have to hide main window first for some reasons - hard to explain why in a few sentences. according to process above, if no error, i should see nothing. but actually i always see the dialog in a flash. it means main window (property sheet) has not been hidden properly and thoroughly. do you know how to hide the dialog without seeing a flash? thx includeh10
When you create dialog you specify its style, and one of the styles is if the window is shown or hidden. Remove shown flag. Use this if you create dialog through CDialog::Create() If you created dialog in Resource editor then doubleclickit to change its properties, and turn off Visible property.