CPropertySheet::CPropertySheet
构造 CPropertySheet 对象。
CPropertySheet( );
explicit CPropertySheet(
UINT nIDCaption,
CWnd* pParentWnd = NULL,
UINT iSelectPage = 0
);
explicit CPropertySheet(
LPCTSTR pszCaption,
CWnd* pParentWnd = NULL,
UINT iSelectPage = 0
);
CPropertySheet(
UINT nIDCaption,
CWnd* pParentWnd,
UINT iSelectPage,
HBITMAP hbmWatermark,
HPALETTE hpalWatermark = NULL,
HBITMAP hbmHeader = NULL
);
CPropertySheet(
LPCTSTR pszCaption,
CWnd* pParentWnd,
UINT iSelectPage,
HBITMAP hbmWatermark,
HPALETTE hpalWatermark = NULL,
HBITMAP hbmHeader = NULL
);
参数
nIDCaption
为属性表将使用声明的ID。pParentWnd
指向属性表的父窗口。 如果 NULL,父窗口将应用程序的主窗口。iSelectPage
最初在上面页的索引。 默认值为第一页添加到页。pszCaption
指向包含元素声明的字符串将使用为属性表。 不能为 NULL。hbmWatermark
对属性表的背景位图的句柄。hpalWatermark
对水印位图和标头位图的调色板的句柄。hbmHeader
"属性页的标头位图的句柄。
备注
若要显示属性表,请调用 DoModal 或 创建。 在第一个参数包含的字符串在属性表的标题栏上。
如果有多个参数(例如,因此,如果使用数组),请使用 构造 而不是 CPropertySheet。
可以自动显示水印和标头图像,如果使用2:1或 CPropertySheet第四个原型,上面和通过 hbmWatermark、 hpalWatermark,和/或 hbmHeader 参数的有效值。
示例
// Declare a CPropertySheet object titled "Simple PropertySheet".
CPropertySheet dlgPropertySheet1(_T("Simple PropertySheet"));
// Declare a CPropertySheet object whose title is specified in the
// IDS_PROPERTYSHEET_TITLE string resource, and the second page is
// initially on top.
CPropertySheet dlgPropertySheet2(IDS_PROPERTYSHEET_TITLE, this, 1);
要求
Header: afxdlgs.h