プロパティ シート キャプション (フレーム ウィンドウのタイトル バーに表示されるテキスト) を指定します。
void SetTitle(
LPCTSTR lpszText,
UINT nStyle = 0
);
パラメーター
nStyle
プロパティ シートのタイトルのスタイルを指定します。スタイルは 0 に PSH_PROPTITLEまたはとして指定する必要があります。スタイルが PSH_PROPTITLEとして設定されている場合、「プロパティ」は、キャプションとして指定されたテキストの後に表示されます。たとえば、SetTitle (「簡易」、 PSH_PROPTITLE) を呼び出すと、「単純なプロパティのプロパティ シート キャプションになります」。lpszText
プロパティ シートのタイトル バーのキャプションとして使用されるテキストへのポインター。
解説
既定では、プロパティ シートのコンストラクターでは、プロパティ シート キャプションのパラメーターを使用します。
使用例
// Declare a CPropertySheet object with a caption "Simple PropertySheet".
CPropertySheet dlgPropertySheet(_T("Simple PropertySheet"));
// Add three pages to the CPropertySheet object. CStylePage, CColorPage,
// and CShapePage are CPropertyPage-derived classes created
// by the Add Class wizard.
CStylePage stylePage;
CColorPage colorPage;
CShapePage shapePage;
dlgPropertySheet.AddPage(&stylePage);
dlgPropertySheet.AddPage(&colorPage);
dlgPropertySheet.AddPage(&shapePage);
// Change the caption of the CPropertySheet object
// from "Simple PropertySheet" to "Simple Properties".
dlgPropertySheet.SetTitle(_T("Simple"), PSH_PROPTITLE);
// Show the CPropertySheet object as MODAL.
dlgPropertySheet.DoModal();
必要条件
ヘッダー : afxdlgs.h