Skip to main content

Common Selection Features

  • 2 minutes to read

Selection Rectangle

The selection rectangle allows end users to drag the mouse pointer over the rows, cells, or cards to select a range of these items.

Marquee Selection

To use this behavior, check that the DataControlBase.SelectionMode and DataViewBase.NavigationStyle properties are set to Row or Cell.

To enable the selection rectangle, set the DataViewBase.ShowSelectionRectangle property to true.

You cannot use the selection rectangle when:

To modify the appearance of the selection rectangle, use the DataViewBase.SelectionRectangleStyle property:

    <Style TargetType="Border">
        <Setter Property="Opacity" Value="0.37" />
        <Setter Property="Background" Value="Green" />

Selector Column

The GridControl allows end users to select rows with the Selector Column (the “Web Style Row Selection” mode).

selector column

You can use this behavior if the DataControlBase.SelectionMode property is not set to MultiSelectMode.None.

To show a Selector Column, set the TableView.ShowCheckBoxSelectorColumn property to true. To allow a row selection only in the Selector Column, set the TableView.RetainSelectionOnClickOutsideCheckBoxSelector property to true.

The Selector Column’s FieldName is set to the CheckBoxSelectorColumnName field value. You can use this field to access the Selector Column in code.


Row and Cell Hover Effects

Set the TableView.HighlightItemOnHover / TreeListView.HighlightItemOnHover property to true to enable hover effects:

Selection Fade

The GridControl fades selected rows when it loses focus.

To disable this behavior, set the DataViewBase.FadeSelectionOnLostFocus to false. This property does not affect the GridControl when it is in the multiple cell selection mode.

See Also