This example shows how to define a cell's context menu. The context menu allows users to delete a row or copy its data to the clipboard.
To specify a context menu, add BarItems to the TableView's RowCellMenuCustomizations collection. The menu item's DataContext property is set to an object of the GridCellMenuInfo type. That allows you to use the Row.Row.[Property_Name] path to access data source properties.
In this example, the Delete button is enabled only for rows whose CanBeDeleted property is true:
<dxb:BarButtonItem Name="deleteRowItem" Content="Delete"
IsEnabled="{Binding Row.Row.CanBeDeleted}"
ItemClick="OnDeleteRow"/>- Window1.xaml (VB: Window1.xaml)
- Window1.xaml.cs (VB: Window1.xaml.vb)
(you will be redirected to DevExpress.com to submit your response)
