Click here to Skip to main content
15,904,416 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I have my controls in a single dialog i want them to be arranged into separate tabs in a tab control. Is this possible? i dont want to create another set of dialog and assign them into my tab control.
Posted
Comments
Sergey Alexandrovich Kryukov 17-Nov-11 23:25pm    
What exactly do you mean by a dialog?
--SA
kramix84 18-Nov-11 0:09am    
Its the form where i place my controls such as edit box, buttons, and the like
Albert Holguin 18-Nov-11 0:52am    
I assume you mean CDialog based dialog? ...did you search code project? I remember seeing an article on the subject not too long ago.
kramix84 18-Nov-11 1:10am    
I saw an article it saids that Cdialog can be assign into a TAB Control as a TAB. But it didnt say if a control can be assigned as an object inside a TAB. Is this possible?

1 solution

You can fake it, by putting in a handler that shows and hides the controls when the user selects a tab.

MyEditCtrl.ShowWindow(SW_HIDE);
MyEditCtrl.ShowWindow(SW_SHOW);

You may need to make the tab control, the parent for the sub controls.

MyEditCtrl.SetParent(&MyTabCtrl);
 
Share this answer
 
v2

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