BCGControlBar Pro for MFC
virtual BOOL CBCGPBaseTabbedBar::AddTab ( CWnd *  pNewBar,
BOOL  bVisible = TRUE,
BOOL  bSetActive = TRUE,
BOOL  bDetachable = TRUE 
)
virtual

Adds a new tab to a tabbed bar.

Returns
Nonzero if a control bar that has been added as a new tab does exist after the function returns. It's 0 if a control bar has been destroyed. It may happen if the added bar was a tabbed control bar.

Call this member function to add a control bar as a new tab to a tabbed control bar. If pNewBar points to an object of type CBCGPBaseTabbedBar, all its tabs are copied and the bar itself is destroyed. In this case a tabbed control bar that has been added is destroyed by AddTab and you have to stop using the pBar pointer.

Parameters
pNewBarA pointer to a control bar to add.
bVisibleSpecifies the visibility state of the added tab.
bSetActiveSpecifies whether to set the added tab active or not.
bDetachableSpecifies whether to set the added tab detachable or not.