Property Pages
-
Hi folks, does anyone know how to change the property page caption inside a Property sheet in MFC? the PropertyPage::SetWindowText does not work, neither changing LPCREATESTRUCT in PropertyPage::OnCreate. This caption is inherited by the property page dialog resource but there should be a way to change it at run-time... Thanx a lot. Regards, andrea
-
Hi folks, does anyone know how to change the property page caption inside a Property sheet in MFC? the PropertyPage::SetWindowText does not work, neither changing LPCREATESTRUCT in PropertyPage::OnCreate. This caption is inherited by the property page dialog resource but there should be a way to change it at run-time... Thanx a lot. Regards, andrea
-
Hi folks, does anyone know how to change the property page caption inside a Property sheet in MFC? the PropertyPage::SetWindowText does not work, neither changing LPCREATESTRUCT in PropertyPage::OnCreate. This caption is inherited by the property page dialog resource but there should be a way to change it at run-time... Thanx a lot. Regards, andrea
Hi, well in the constructor of your derived CPropertyPage try this code:
m_strCaption = m_aToolText.Anzeige(1); m_psp.pszTitle = m_strCaption; m_psp.dwFlags |= PSP_USETITLE;
m_strCaption is a CString variable you must provide. The text to dbe displayed comes from elsewhere or you put in directly. m_psp is variable/struct for the proprety sheet, and is already defined in the base class by the MFC. I think you can change m_strCaption afterwards any way you want. But havn't tried this one out. hope this helps G. Steudtel -
I'm using this before adding the property page to the property sheet...
MyPP.m_psp.dwFlags |= PSP_USETITLE;
MyPP.m_psp.pszTitle = "The new title...";Hope this helps
UAO IT WORKS!!! Thanx a lot Regards andrea:):)