When the BKS_BUTTONAREA style is set, a common button area is created to contain a set of push buttons which is the same on each notebook page. These buttons are children of the notebook window. Buttons common to all pages in the notebook can be added, and specific buttons for a given notebook page may also be added as needed. The button area is placed opposite the major tabs of the notebook.

Common buttons behave exactly like ordinary push buttons except that they are positioned and sized automatically by the notebook control. Notification messages from the buttons are sent to the current notebook page. Buttons common to all notebook pages are handled by the BKM_SETNOTEBOOKBUTTONS message. Buttons specific to a notebook page can be created as children of that notebook page using the BS_NOTEBOOKBUTTON style.

If you create BS_NOTEBOOKBUTTON style buttons for a notebook page, they will override the common buttons created by BKM_SETNOTEBOOKBUTTONS. For instance, if you want to have buttons Help and Default available on all pages but one, use the BKM_SETNOTEBOOKBUTTONS message to create them, but create BS_NOTEBOOKBUTTON style buttons on the page requiring special buttons, and they will be the ones shown when that particular notebook page is displayed.

The states of the buttons created using BKM_SETNOTEBOOKBUTTONS are not changed when the notebook page turns.


[Back] [Next]