BCGControlBar Pro for MFC
CBCGPPropSheetCategory* CBCGPPropertySheet::AddTreeCategory ( LPCTSTR  lpszLabel,
int  nIconNum = -1,
int  nSelectedIconNum = -1,
const CBCGPPropSheetCategory pParentCategory = NULL 
)

Adds a new category to the tree navigation control.

Returns
A valid pointer to new category. You should use this pointer in subsequent calls to AddPageToTree() and AddTreeCategory. The memory allocated for the category object is freed automatically.

Use this function to add a new category to the tree navigation control. If you set pParentCategoty to NULL, the new category will be added as a top level item.

You must call CBCGPPropertySheet::SetLook with CBCGPPropertySheet::PropSheetLook_Tree style before the property sheet has been created.

Parameters
lpszLabelSpecifies the category name.
nIconNumIcon index.
nSelectedIconNumSelected icon index.
pParentCategoryPoints to a parent category. Can be NULL.