Cells

  • 2 minutes to read

Vertical grids consist of rows, records, and cells. If a row corresponds to a single field in the data source, there is only one cell in an intersection of a row and record. If a row corresponds to multiple data source fields, there are multiple cells in the row and record intersection. This topic shows how to identify a cell to get or set its value.

How to Identify a Cell

Use the GetCellValue or SetCellValue method to get or set a cell value. A cell is identified by a row, record index and, for multi-editor rows, cell index. To specify a row, use the corresponding EditorRow, MultiEditorRow or RowProperties object. The image below illustrates cells in a single- and multi-editor row.

// Cell is identified by a single-editor row object and record index.
vGridControl.SetCellValue(gridRow: erName, recordIndex: 0, value: "Touareg");
// Cell is identified by a multi-editor row object, record index and cell index.
vGridControl.SetCellValue(meRow: merTransmmision, recordIndex: 0, cellIndex: 1, value: 8);
// Cell is identified by a row properties object and record index.
vGridControl.SetCellValue(props: merpTransmissionSpeeds, recordIndex: 0, value: 8);
See Also