DxContextMenuItem Class

Defines an item in the Context Menu component.

Namespace: DevExpress.Blazor

Assembly: DevExpress.Blazor.dll

Declaration

public class DxContextMenuItem :
    DxComponent<ContextMenuItemViewModel>

Remarks

The DxContextMenuItem class implements the functionality of an individual item in the unbound Context Menu component. Use the Items property to define the component's item collection.

<DxContextMenu>
    <Items>
        <DxContextMenuItem Text="Sort By" IconUrl="images/Sort_by.svg">
            <Items>
                <DxContextMenuItem Text="Name"></DxContextMenuItem>
                <DxContextMenuItem Text="Size"></DxContextMenuItem>
                <DxContextMenuItem Text="Type"></DxContextMenuItem>
            </Items>
        </DxContextMenuItem>
        <DxContextMenuItem Text="Copy" IconUrl="images/Copy.svg" BeginGroup="true"></DxContextMenuItem>
        <DxContextMenuItem Text="Cut" IconUrl="images/Cut.svg"></DxContextMenuItem>
        <DxContextMenuItem Text="Remove" IconUrl="images/Clear.svg"></DxContextMenuItem>
        <DxContextMenuItem Text="Select All" BeginGroup="true"></DxContextMenuItem>
    </Items>
</DxContextMenu>

ContextMenu Items

NOTE

Online Demo: Context Menu

Inheritance

Object
ComponentBase
DevExpress.Blazor.Base.DxDecoratedComponent
DxComponentBase
DevExpress.Blazor.Internal.DxComponent
DevExpress.Blazor.Internal.DxComponent<DevExpress.Blazor.Navigation.Internal.ContextMenuItemViewModel>
DxContextMenuItem
See Also