Select the product you need help with
HOWTO: How to Change Default Button on CPropertySheetArticle ID: 140587 - View products that this article applies to. This article was previously published under Q140587 On This PageSUMMARY
When a modal CPropertySheet is created, the default button is the OK
button. To change the default to a different button, derive a class from
CPropertySheet, override OnInitDialog(), and send a message of DM_SETDEFID
to the sheet with the ID of the new button.
MORE INFORMATION
The IDs of the buttons that are created in a modal CPropertySheet are:
IDOK - OK button IDCANCEL - Cancel button ID_APPLY_NOW - Apply button IDHELP - Help button If you want a button other than these default buttons to have the default focus, you have to create the button, say IDC_MYBUTTON, and set focus to that button using: Sample CodePropertiesArticle ID: 140587 - Last Review: November 21, 2006 - Revision: 2.1 APPLIES TO
|



Back to the top








