Share via


CMFCToolBarsCustomizeDialog::FillCategoriesComboBox

Populates the provided CComboBox object with the name of each command category in the Customize dialog box.

void FillCategoriesComboBox(
   CComboBox& wndCategory,
   BOOL bAddEmpty = TRUE
) const;

Parameters

  • [out] wndCategory
    A reference to the CComboBox object to populate.

  • [in] bAddEmpty
    A Boolean value that specifies whether to add categories to the combo box that do not have commands. If this parameter is TRUE, empty categories are added to the combo box. Otherwise, empty categories are not added.

Remarks

This method is like the CMFCToolBarsCustomizeDialog::FillCategoriesListBox method except that this method works with a CComboBox object.

This method does not clear the contents of the CComboBox object before populating it. It guarantees that the All Commands category is the final item in the combo box.

You can add new command categories by using the CMFCToolBarsCustomizeDialog::AddButton method. You can change the name of an existing category by using the CMFCToolBarsCustomizeDialog::RenameCategory method.

The CMFCToolBarsKeyboardPropertyPage and CMFCKeyMapDialog classes use this method to categorize keyboard mappings.

Requirements

Header: afxtoolbarscustomizedialog.h

See Also

Reference

CMFCToolBarsCustomizeDialog Class

Hierarchy Chart

CComboBox Class

CMFCToolBarsCustomizeDialog::FillCategoriesListBox

CMFCToolBarsCustomizeDialog::AddButton

CMFCToolBarsCustomizeDialog::RenameCategory

CMFCKeyMapDialog Class