Devexpress Gridcontrol Multiselect without using indicator column

16.9k Views Asked by At

Is there any way to allow the user to do a multiple row selection just by clicking and dragging along cells within the actual grid? I.e. Without using the indicator column?

2

There are 2 best solutions below

0
On

To achieve this behavior, you need to handle the MouseDown and MouseMove events and select rows programmatically. You also need to enable the multi-selection feature and switch the multi-selection mode to "CellSelect" to be able to select individual cells.

download the attached sample from this link and customize it to implement your functionality...

MultiSelect Rows & Cells simultaneously

check the following thread, which using indicator but you can customize it hiding indicator and setting select option to cellselect etc... "mulitiselect without CTRL key" on Devexpress..

search result that help you implement that you are looking for...

0
On

You can do that by cell using just properties by setting the following properties located in Gridview.Options

 Multiselect = True
 MultiSelectMode = CellSelect
 UseIndicatorForSelection = False

If you need to do it by entire rows, you are stuck writing that functionality yourself using GridView.CalcHitInfo and various events.