Skip to main content

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

BarItemCollectionBase<T>.Remove(String) Method

Removes a tab, group, or item with the specified name from a tab, group, or item collection.

Namespace: DevExpress.Blazor.Office

Assembly: DevExpress.Blazor.v24.2.dll

NuGet Package: DevExpress.Blazor

#Declaration

C#
public bool Remove(
    string name
)

#Parameters

Name Type Description
name String

The tab, group, or item name.

#Returns

Type Description
Boolean

true if the tab, group, or item is removed; otherwise, false.

#Remarks

The Remove method overloads allow you to remove the following bar elements:

The following code snippet removes tabs from the ribbon.

Razor
<DxRichEdit CustomizeRibbon=OnCustomizeRibbon />

@code {
    void OnCustomizeRibbon(IRibbon ribbon) {
        // Removes the tab with index 0
        ribbon.Tabs.Remove(0);
        // Removes the File tab
        ribbon.Tabs.Remove(RichEditRibbonTabNames.File);

    }
}

Run Demo: Toolbar Customization Run Demo: Ribbon Customization

See Also