Click here to Skip to main content
15,905,508 members
Please Sign up or sign in to vote.
4.00/5 (1 vote)
See more:
I have a C++ dialog, which contains:

1.) ListBox
2.) 3 checkboxes
3.) Two tree controls and
4.) 5 buttons.

I kind of have to move, the ListBox and the two Checkboxes into a different class and should add this class(the cutom control with two listboxes and two checkboxes) dynamically at the time of creation of the dialog.

Is there any good example for this. I have seen so many examples of code project, but everything is actually creating a custom control dynamically using the CWnd::Create function.

But i have more than one control to create (a custom class control with three different control of listbox and 2 checkboxes).

How do i do this? is there any nice example?
Posted

1 solution

You could always do it the easy way and create a dialog with those three controls and then insert that dialog n times.

Take a look here: link1[^], and link2[^].

If that approach could work for you you can always look for more help searching for "child dialog".

Hope this helps you. :thumbsup:
 
Share this answer
 
Comments
amarasat 23-Jun-11 17:27pm    
Thanks a lot Joan, Scrollable Dialog helped a lot.
Joan M 23-Jun-11 19:22pm    
I'm glad that it has helped you!

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