Skip to content

DevExpress-Examples/blazor-dxgrid-show-context-menu

Repository files navigation

Blazor Grid - Display a Context Menu

You can display a Context Menu when you right-click any Blazor Grid element. In this example, a click on a column header or row invokes the Context Menu.

Grid with Context Menu for a column

Add the oncontextmenu:preventDefault to disable the standard browser context menu. In the Grid's CustomizeElement event handler, subscribe to the contextmenu event (displays the custom Context Menu).

The GridContextMenuContainer component contains Context Menu components. The GridContextMenuHelper class implements Context Menu's item generation, manages state, and includes the click handlers that use the Blazor Grid's API to execute commands.

Files to Review

Documentation

Video

More Examples

Does this example address your development requirements/objectives?

(you will be redirected to DevExpress.com to submit your response)

About

Show the Context Menu when you right-click a Grid element.

Topics

Resources

License

Stars

Watchers

Forks

Contributors 6