Click here to Skip to main content
15,860,859 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi!
I design mfc dialog based application in which first i design main parent window containing multiple child windows with tab control,it works fine.After i add one dialog before parent dialog and call parent dialog from it.So call to new dialog insert Back button on parent dialog,it works well,but second time parent dialog failed to open and application close.So how to save state of parent dialog second time initialization.I used methodlogy for above scenario given below:
I call new dialog in OnInitDialog() of parent dialog as DoMOdal() method.
Back button code given below:
C#
void CParent::OnBnClickedBack()
{
    UpdateData(TRUE);
    NewDlg dlg=new NewDlg();
    OnOK();
    dlg.DoModal();
}
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900