Skip to main content

TcxGridTableController.SelectCells(TcxGridColumn,TcxGridColumn,Integer,Integer) Method

Selects specific cells within a (Banded) Table View.

Declaration

procedure SelectCells(AFromColumn: TcxGridColumn; AToColumn: TcxGridColumn; AFromRowIndex: Integer; AToRowIndex: Integer);

Parameters

Name Type
AFromColumn TcxGridColumn
AToColumn TcxGridColumn
AFromRowIndex Integer
AToRowIndex Integer

Remarks

Call the SelectCells method to select all the cells in the columns within the column range defined by the AFromColumn and AToColumn parameters and records (rows) within the row range defined by the AFromRowIndex and AToRowIndex parameters. The AFromRowIndex and AToRowIndex parameters designate the bound row indexes for the rows in the row range that specifies the record selection while the AFromColumn and AToColumn parameters represent bound columns for the column range that specifies the columns whose cells will be selected. The order in which parameters in each parameter pair are specified does not matter, e.g. the column denoted by the AToColumn can precede (using its horizontal position) the column which corresponds to the AFromColumn parameter.

Note

the SelectCells method automatically clears the current selection (if any) within the View prior to making a new one.

In order to select all columns (their cells) within the current record selection, use the SelectAllColumns method.

To enable cell (column) selection, set the View’s OptionsSelection.CellMultiSelect property to True.

Refer to the SelectedRecords and SelectedColumns properties for details on selected records and columns.

See Also