You are viewing help content for pre-release software. This document and the features it describes are subject to change. Switch to the current version.

DefaultSummaryMenuItemNames Class

Contains default item captions displayed within the summary context menu.

Namespace: DevExpress.Xpf.Grid

Assembly: DevExpress.Xpf.Grid.v20.2.dll

Declaration

public class DefaultSummaryMenuItemNames
Public Class DefaultSummaryMenuItemNames

Remarks

Refer to the Localizing WPF Controls via Localizer Objects topic for information on how to change default menu item captions.

Examples

The following example removes an item from the Total Summary panel's context menu:

View Example

In XAML

Add the RemoveBarItemAndLinkAction object to the DataViewBase.TotalSummaryMenuCustomizations collection. Specify the BarItemActionBase.ItemName property with the menu item name from the DefaultSummaryMenuItemNames class.

<dxg:TableView.TotalSummaryMenuCustomizations>
    <dxb:RemoveBarItemAndLinkAction ItemName="{x:Static dxg:DefaultSummaryMenuItemNames.Customize}" />
</dxg:TableView.TotalSummaryMenuCustomizations>

In Code

Handle the DataViewBase.ShowGridMenu event.

<dxg:TableView ShowGridMenu="ShowGridMenu" />
void ShowGridMenu(object sender, GridMenuEventArgs e) {
    if (e.MenuType == GridMenuType.TotalSummary) {
        e.Customizations.Add(new RemoveAction { ElementName = DefaultSummaryMenuItemNames.Customize });
    }
}

Inheritance

Object
DefaultSummaryMenuItemNames
See Also