CMFCPropertySheet::AddPageToTree

添加新的属性页添加到树控件。

void AddPageToTree(
   CMFCPropertySheetCategoryInfo* pCategory,
   CMFCPropertyPage* pPage,
   int nIconNum=-1,
   int nSelIconNum=-1 
);

参数

  • [in] pCategory
    对父树节点的关联指定的页的指针或 NULL 与顶级节点。 调用 CMFCPropertySheet::AddTreeCategory 方法获取此指针。

  • [in] pPage
    "属性页对象的指针。

  • [in] nIconNum
    图标的从零开始的索引或-1,如果未使用图标。 当页未选中时,该图标将显示在树控件属性页旁边显示。 默认值为 -1。

  • [in] nSelIconNum
    图标的从零开始的索引或-1,如果未使用图标。 当页时,该图标将显示在树控件属性页旁边显示。 默认值为 -1。

备注

此方法将属性页作为树控件的叶。 若要添加属性页中,创建一 CMFCPropertySheet 对象,使用的调用 look 参数的 CMFCPropertySheet::SetLook 方法设置为 CMFCPropertySheet::PropSheetLook_Tree,然后使用此方法添加属性页。

要求

标头: afxpropertysheet.h

请参见

参考

CMFCPropertySheet选件类

层次结构图

CMFCPropertySheet::AddTreeCategory