Occurs in multiple row select mode when an end-user tries to select a grid row (node) and allows you to prevent selecting a particular row (node).
NuGet Package: DevExpress.Wpf.Grid.Core
public event CanSelectRowEventHandler CanSelectRow
Public Event CanSelectRow As CanSelectRowEventHandler
The CanSelectRow event's data class is CanSelectRowEventArgs. The following properties provide information specific to this event:
|CanSelectRow||Gets or sets whether an end-user can select the processed row.|
|Row||Gets a data row object that corresponds to the processed row (or treelist node).|
|RowHandle||Gets the handle of a processed row.|
|View||Gets a GridControl view to which the processed row belongs.|
Handle the CanSelectRow event to dynamically prevent end-users from selecting particular rows.
Set the event argument’s CanSelectRowEventArgs.CanSelectRow property to false to prevent an end-user from selecting a processed row. Use the CanSelectRowEventArgs.Row, and CanSelectRowEventArgs.RowHandle event argument properties to retrieve a processed row.
Handle the DataViewBase.CanUnselectRow event to prevent end-users from unselecting a particular row.