SECTabWndBase::AddTab
A new tab is created and appended after the last tab. The label specified by lpszLabel becomes the new tab’s label.
The second parameter is treated as client data which is associated with the tab. Usually, this will be a pointer to a CWnd - derived class which should be shown when its associated tab is active. However, the pClient parameter doesn’t have to be a CWnd-derivative since the SECTabControl (and its implementations) only store this data.
Upon successful completion, this function returns a pointer to the new tab. You can use this pointer to initialize or change any tab attributes immediately following the call to AddTab.
Defined in: tabwndb.cpp
Syntax
AddTab(CWnd* pWnd, LPCTSTR lpszLabel)
AddTab(CRuntimeClass* pViewClass, LPCTSTR lpszLabel, CCreateContext* pContext, UINT nID)
Return Value
A pointer to the new tab or NULL if the call failed.
Parameters
pWnd
The window to associate with the tab.
lpszLabel
Label to be shown on the tab.
pViewClass
Specifies the CRuntimeClass of the new view.
pContext
A pointer to a creation context used to create the view (usually the pContext passed into the parent frame’s overridden CFrameWnd::OnCreateClient member function in which the tabbed window is being created).
See Also