Solved

CTabCtrl inside a dialog?

Posted on 1998-03-29
2
974 Views
Last Modified: 2008-02-01
Need source to implement CTabCtrl in a dialog.  I created all of my pages as dialogs and would rather use CTabCtrl instead of property pages in my main dialog box.  I don't want the APPLY button or any of the buttons that come along with CPropertyPage but would like to setup each page in the same manner.  Am I forced to use CPropertyPage?  I placed the CTabCtrl control in my main dialog and in OnInitDialog was successful in adding the tabs but now need to place the actual dialogs on each of the pages.  Help...point me to some good code...
0
Comment
Question by:xlr8tn
2 Comments
 
LVL 3

Accepted Solution

by:
LucHoltkamp earned 50 total points
ID: 1183924
The CTabContral is just a simple control, you have to put ALL your controls in ONE dialog and hide an disable them yourself according to the position of the tab. This will also result in flickering on the screen as the controls are switched on and off.
For this reason it's not a good idea to use CTabControl in dialogs. Better use a propertypage.

.luc.
0
 

Author Comment

by:xlr8tn
ID: 1183925
I found an example that allowed me to create my tabs using CPropertyPage referencing my dialogs.  There was a trick involved with using a picture box and then in OnInitDialog changing some of the attributes.  I actually got it to work with very little effort.  I guess what I was really looking for was how to get rid of the buttons that come on a propertysheet (i.e. Apply, Cancel, and OK).  
0

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

Suggested Solutions

In days of old, returning something by value from a function in C++ was necessarily avoided because it would, invariably, involve one or even two copies of the object being created and potentially costly calls to a copy-constructor and destructor. A…
Introduction This article is the first in a series of articles about the C/C++ Visual Studio Express debugger.  It provides a quick start guide in using the debugger. Part 2 focuses on additional topics in breakpoints.  Lastly, Part 3 focuses on th…
The goal of the video will be to teach the user the difference and consequence of passing data by value vs passing data by reference in C++. An example of passing data by value as well as an example of passing data by reference will be be given. Bot…
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now