Domanda

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...

È stato utile?

Soluzione

OK,

I got the solution, as follow code

TC_ITEM TabCtrlItem;

switch(m_tabCtrl.GetCurSel())
{
case TAB1:
    TabCtrlItem.mask = TCIF_TEXT;
    TabCtrlItem.pszText = _T("Some Text");
    m_tabCtrl.SetItem(TAB1, &TabCtrlItem );
Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top