|
-
October 8th, 1999, 02:20 PM
#1
Adding controls to CTabCtrl - 3rd post
can anyone out there explain the best way to add controls to a CTabCtrl? Is there any way to do it using the dialog editor? So far, no one has been able to help. If you can, I would really appreciate it. Thanks a lot in advance.
Arun
-
October 8th, 1999, 05:01 PM
#2
Re: Adding controls to CTabCtrl - 3rd post
You can do it in the editor, by inserting tab control to existing dialog, invoking ClassWizard to add member variables. Class Wizard will show you CTabCtrl as a type, this will subclass tab control for you.
Use that dialog as regular dialog or form view.
You will have to create tabs.
You can add as many controls as you need, but you will be responsible for showing/hiding them as different tabs are selected.
Why not to use property sheet and property pages?
There are only 10 types of people in the world:
Those who understand binary and those who do not.
-
October 8th, 1999, 05:07 PM
#3
Re: Adding controls to CTabCtrl - 3rd post
I need the tabs as part of a larger CFormView, with other controls on it. I was told that I could not use prop sheet/page for this. I have added a CTabCtrl member variable to the CFormView derived class, and have created the tabs, but how do I easily put controls on them? Is there any way to do it through the dialog editor?
Thanks a lot for your help.
Arun
-
October 8th, 1999, 05:36 PM
#4
Re: Adding controls to CTabCtrl - 3rd post
I really don’t know who told you that you can’t use Property sheet in a form view.
If you need only tabbed control, you can use property sheet embedded directly in the frame!
There is article I wrote and many more once you go to a property sheet in "Controls related source code sections" from a home page http://www.codeguru.com/.
There are only 10 types of people in the world:
Those who understand binary and those who do not.
-
October 11th, 1999, 09:50 AM
#5
Re: Adding controls to CTabCtrl - 3rd post
Thanks! I got it to work.
Arun
-
August 18th, 2000, 07:00 PM
#6
Re: Adding controls to CTabCtrl - 3rd post
HOW did you get his to work? CTabCtrl or propertysheets? I'm hitting a wall here.
-
August 20th, 2000, 09:37 AM
#7
Re: Adding controls to CTabCtrl - 3rd post
For TabCtrl, maybe the main problem is the order in which controls are created. You should firstly put all the controls in place, then draw a TabCtrl 'embracing' them, or draw TabCtrl first,
then edit .rc manually, just move other ctrls ahead of your TabCtrl. In view.cpp, use ShowWindow simply. It works, but maybe is not the best method.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|