CMFCToolBarsCustomizeDialog::RemoveButton

Removes the button with the specified command ID from the specified category, or from all categories.

int RemoveButton(
   UINT uiCategoryId,
   UINT uiCmdId 
);
int RemoveButton(
   LPCTSTR lpszCategory,
   UINT uiCmdId 
);

Parameters

  • [in] uiCategoryId
    Specifies the category ID from which to remove the button.

  • [in] uiCmdId
    Specifies the command ID of the button.

  • [in] lpszCategory
    Specifies the name of the category from which to remove the button.

Return Value

The zero-based index of the removed button, or -1 if the specified command ID was not found in the specified category. If uiCategoryId is -1, the return value is 0.

Remarks

To remove a button from all categories, call the first overload of this method and set uiCategoryId to -1.

Requirements

Header: afxToolBarsCustomizeDialog.h

See Also

Reference

CMFCToolBarsCustomizeDialog Class

Hierarchy Chart