embed multiple child dialogs on main dialog
-
Hi All, I need to design a dialog box which has 2 sections. the left section is a tree control and right section displays various controls.Based on the user's selection in the tree control, I need to display different controls(like property pages...)in the right section.I have created separate dialogs for each of the selections and I need to embed this template onto the main dialog upon user's selection.Please let me know how to achieve this. Thanks in advance Raghu
-
Hi All, I need to design a dialog box which has 2 sections. the left section is a tree control and right section displays various controls.Based on the user's selection in the tree control, I need to display different controls(like property pages...)in the right section.I have created separate dialogs for each of the selections and I need to embed this template onto the main dialog upon user's selection.Please let me know how to achieve this. Thanks in advance Raghu
Raghunandan wrote:
need to design a dialog box which has 2 sections. the left section is a tree control and right section displays various controls.Based on the user's selection in the tree control, I need to display different controls(like property pages...)in the right section.I have created separate dialogs for each of the selections and I need to embed this template onto the main dialog upon user's selection.Please let me know how to achieve this.
Make the other dialogs as child and use the following code to create the dialogs in main Dialog.
CDialog *dlg=new CDialog() dlg->Create(Dialog ID); dlg->ShowWindow(SW_SHOW);
Use MoveWindow to set the dialog at appropriate position. or set the dialog co-ordinates. Knock out 't' from can't, You can if you think you can :cool: -
Hi All, I need to design a dialog box which has 2 sections. the left section is a tree control and right section displays various controls.Based on the user's selection in the tree control, I need to display different controls(like property pages...)in the right section.I have created separate dialogs for each of the selections and I need to embed this template onto the main dialog upon user's selection.Please let me know how to achieve this. Thanks in advance Raghu
You can use SetWindowPos and put the dialogs in modeless form. Somethings seem HARD to do, until we know how to do them. ;-) _AnShUmAn_
-
Hi All, I need to design a dialog box which has 2 sections. the left section is a tree control and right section displays various controls.Based on the user's selection in the tree control, I need to display different controls(like property pages...)in the right section.I have created separate dialogs for each of the selections and I need to embed this template onto the main dialog upon user's selection.Please let me know how to achieve this. Thanks in advance Raghu
-
Set the Style property of Dialogs as child . Now do as follows in your implementation file : CDialog *dlg= new CChildDialog(); dlg->SetWindowPos(...); dlg->ShowWindow(SW_SHOW); Cheers "Peace of mind through Technology"
the problem with these solutions are that the child dialog get closed upon pressing escape or enter when the focus in any of the controls Raghu
-
the problem with these solutions are that the child dialog get closed upon pressing escape or enter when the focus in any of the controls Raghu