ColumnView.RowDeleting Event
Fires when a data row is about to be deleted.
Namespace: DevExpress.XtraGrid.Views.Base
Assembly: DevExpress.XtraGrid.v22.2.dll
NuGet Package: DevExpress.Win.Grid
Declaration
Event Data
The RowDeleting event's data class is RowDeletingEventArgs. The following properties provide information specific to this event:
Property | Description |
---|---|
Cancel | Gets or sets whether the current event (the row deletion) needs to be canceled. |
ListSourceIndex | Gets the index of the current row in the data source. Inherited from RowDeletedEventArgs. |
Row | Gets the currently processed row. Inherited from RowDeletedEventArgs. |
RowHandle | Gets the row handle (id) that identifies the position of the current row in the control. Inherited from RowDeletedEventArgs. |
Remarks
To delete a row in the ColumnView, you can use the ColumnView.DeleteRow and ColumnView.DeleteSelectedRows methods. The RowDeleting event allows you to prevent row deletion. To do this, set the RowDeletingEventArgs.Cancel property to true.