How to change caption of Property Page
-
Hello, I want to change the caption of my Property Page at runtime. SetWindowText does not the trick. The Caption Text specified in the Dialog editor is always used, no change after a SetWindowText call in OnInitDialog. Any Idea ?
-
Hello, I want to change the caption of my Property Page at runtime. SetWindowText does not the trick. The Caption Text specified in the Dialog editor is always used, no change after a SetWindowText call in OnInitDialog. Any Idea ?
Wow - deja vu, I am having the EXACT SAME PROBLEM. Although my scenario is a little different - my property page is in Wizard mode. If you know the new title when the constructor of the property page is called, you can put this in the property page constructor:
m_psp.dwFlags |= PSP_USETITLE; m_psp.pszTitle = "Some New Title";
BUT... this will NOT work after the property page has already been created! If anyone knows of a way to change the property page title (especailly in a wizard-mode property page) at run-time (NOT in the constructor) that actually works, I'm all ears. I hate property sheets.. one of these days I'll write my own custom version of them and avoid all the silly restrictions they have. Even a broken clock is right twice a day. -
Hello, I want to change the caption of my Property Page at runtime. SetWindowText does not the trick. The Caption Text specified in the Dialog editor is always used, no change after a SetWindowText call in OnInitDialog. Any Idea ?
-
Hello, I want to change the caption of my Property Page at runtime. SetWindowText does not the trick. The Caption Text specified in the Dialog editor is always used, no change after a SetWindowText call in OnInitDialog. Any Idea ?
There is a PROPSHEETPAGE pointed to by the m_psp class member of a property. This contains a field pszTitle which contains the the title of the property page. Yoy will need to set the PSP_USETITLE flag in the dwflags of the property sheet to use this. You might give this a try.
-
Check out this knowledge base item: http://support.microsoft.com/default.aspx?scid=KB;en-us;q141487[^] I was able to use the third method and it works. Woohoo! Even a broken clock is right twice a day.
Cool, it works for me too. Thanks