GridOptionsSelection.MultiSelectMode Property
Gets or sets whether multiple cells or rows can be selected.
Namespace: DevExpress.XtraGrid.Views.Grid
Assembly: DevExpress.XtraGrid.v24.2.dll
Declaration
[DefaultValue(GridMultiSelectMode.RowSelect)]
[XtraSerializableProperty]
public virtual GridMultiSelectMode MultiSelectMode { get; set; }
Property Value
Type | Default | Description |
---|---|---|
GridMultiSelectMode | RowSelect | A GridMultiSelectMode enumeration value which specifies whether multiple cells or rows can be selected. |
Available values:
Name | Description |
---|---|
RowSelect | Multiple rows can be selected via the mouse and keyboard. Individual cells cannot be selected. |
CellSelect | Individual cells and blocks of cells can be selected. This option is not supported in Advanced Banded Grid Views. |
CheckBoxRowSelect | Multiple rows can be selected via the mouse, keyboard and built-in Check column (which displays check boxes in each row). Individual cells cannot be selected. |
Property Paths
You can access this nested property as listed below:
Object Type | Path to MultiSelectMode |
---|---|
GridView |
|
Remarks
Multiple row (cell) selection is allowed, and therefore the MultiSelectMode property is in effect if the ColumnViewOptionsSelection.MultiSelect property is set to true.
gridView1.OptionsSelection.MultiSelect = true;
gridView1.OptionsSelection.MultiSelectMode = DevExpress.XtraGrid.Views.Grid.GridMultiSelectMode.CheckBoxRowSelect;
See the following topics for more information:
- Multiple Row and Cell Selection
- Multiple Row Selection via Built-In Check Column and Selection Binding
Demos
- Cell Selection module in the XtraGrid MainDemo
- Web Style Row Selection module in the XtraGrid MainDemo
Online Video
DevExpress WinForms: Web Style Row Selection.
Related GitHub Examples
The following code snippets (auto-collected from DevExpress Examples) contain references to the MultiSelectMode property.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.