CTabCtrl is a Windows user interface control for managing a set of tab windows or tab panes. The class appears in a number of different window frame works such as MFC, WTL, and others.
Questions tagged [ctabctrl]
29 questions
0
votes
0 answers
CTabCtrl DeleteItem does not work in every case
i have a function which loops through map (the map contains the index of my CTabCtrl-Tab and the ID of the Document which is shown in the Tab) and if the ID of the current selected Tab is not similar to the ID of the current looped tab, the tab…

Orothred
- 11
- 2
0
votes
0 answers
CTabCtrl, enabling and disabling tabs
Using Visual C++ MFC.
I have a dialog page, which contains a tab control object. I've created my own tab control class derived from CTabCtrl, where I created all my tab pages contained in an array, like so:
tabArray[0] = new TabPage;
tabArray[1] =…

captainjim
- 127
- 1
- 1
- 6
0
votes
1 answer
How to resize a CTabCtrl to fit its contents
I have a CTabCtrl in my program and 3 "child" *CFormView*s that I show/hide whenever the user changes the active tab.
Instead of using a fixed size, I'd like to resize the enclosing CTabCtrl to match the size of the largest CFormView.

Fábio
- 3,291
- 5
- 36
- 49
0
votes
0 answers
Owner-draw with CTabCtrl using MFC
Using VS 2015. I have a dialog-based app (NOT a PropertySheet), and have a CTabCtrl-derived object in which I want to disable specific tabs. From what I've googled, owner-draw is the way to go. Fine, can understand that.
What I would like to do is…

MPW
- 329
- 2
- 13
0
votes
1 answer
Controls handling in a CTabCtrl MFC
I have a MFC application that have a class who inherits from CTabCtrl, on my Main Dialog::OnInit() Method I do.
tabCtrl.InsertItem(0, _T("Tab 1"));
tabCtrl.InsertItem(1, _T("Tab…

Pablo Iocco
- 31
- 3
0
votes
1 answer
I am extending CTabCtrl but but cant insert any tabs
I am extending CTabCtrl but when I call InsertItem on my extended object none tab gets inserted. Who knows why is that. What do I do wrong?
class MyTabControl : public CTabCtrl
{
public:
MyListControl m_listCtrl;
void …

maniak
- 21
- 2
0
votes
1 answer
MFC's CTabCtrl::HitTest function returns "1" for any tab clicked
Hi (although greeting usually gets deleted),
I'm using the MFC's CTabCtrl control and try to determine which tab was clicked (to drag & drop it later). Should be quite easy I thought - anyway got stuck with the HitTest function which returns "1" for…

tomascz
- 235
- 1
- 13
0
votes
1 answer
Adding tabs to CTabCtrl in MFC
I am trying to add a CTabCtrl into my MFC application. I am trying to follow the MSDN directly.
*MSDN: Adding Tabs to Tab Control
Here is what I have tried:
DDX_Control(pDX, TAB1, m_TabCtrl);
TC_ITEM ti;
ti.mask = TCIF_TEXT;
ti.pszText = _T("First…

Kyle Williamson
- 2,251
- 6
- 43
- 75
0
votes
1 answer
Creating a class derived from CTabCtrl
I am following a tutorial to use CTabCtrl. The tutorial is asking me to create a class that is derived from CTabCtrl. I am unsure if I am doing this correctly. This is the header for my custom class.
#pragma once
// CTabbyControl
class…

Kyle Williamson
- 2,251
- 6
- 43
- 75
0
votes
1 answer
MFC, How do I change the capiton of TabCtrl
I know the InsertItem is for add new tab in tabctrl, but I need change the caption of tab after create, I use keyword tabctrl and caption to search the old article ,but no relation problem to solve it, hot do I change the caption of tab page...

user1753112
- 203
- 2
- 17
0
votes
1 answer
How to notify all controls within CTabCtrl what they should be redrawn(should change their size)?
I got an instance of MYListCtrl which is derived class from the CListCtrl within CTabCtrl instance.
I have implemented onSize method for MYCListCtrl, and mapped it to the WM_SIZE message.
I want to change size of MYListCtrl when window which…

spin_eight
- 3,925
- 10
- 39
- 61
0
votes
1 answer
Tab Control draw on Enter Key
So I have an issue that I assume has been explored before but I can’t seem to find anything on it. I made a custom Tab Control class that is completely custom drawn and shows/hides CDialog object as the user clicks on different tabs. To do this I…

JBode
- 23
- 3
0
votes
1 answer
MFC: How to Identfy if Dialog was created using CPropertySheet or CTabCtrl
In reference to this question:Which is prefered CTabCtrl vs CPropertySheet
I have a DDK that uses MFC which I am new to. The basic example from the DDK implements a simple dialog box with 3 tabs with the "Ok" and "Cancel" button on the right side…

justin
- 243
- 2
- 6
- 15
0
votes
1 answer
Making an MFC CTabCtrl not use the full control width for drawing tabs
We have a somewhat involved request for a change in our application, which is to make one of our tab controls only have access to part of the width of the control for the purposes of drawing the tabs, so that we can stick some additional status text…

mwigdahl
- 16,268
- 7
- 50
- 64