[Overview][Constants][Types][Classes][Procedures and functions][Index] Reference for unit 'DBGrids' (#lcl)

TCustomDBGrid.Columns

Columns provides access to columns defined for the database grid control.

Declaration

Source position: dbgrids.pas line 515

protected property TCustomDBGrid.Columns : TDBGridColumns
  read GetColumns
  write SetColumns;

Description

Columns is a TDBGridColumns property that provides access to columns defined for the database grid control. Columns reimplements the property defined in the ancestor class. The items in the collection are represented as TColumn instances which are derived from TGridColumn. The TColumn instances include additional properties and methods which identify the field name, TField instance, and display format for the column. The properties defined in TGridColumn are also available.

TColumn instances in Columns can be explicitly created in the IDE at design-time, or automatically added when the OptionsExtra property includes the value dgeAutoColumns.

Use of the Columns property is not required. When left empty, the fields displayed on the grid and their attributes are retrieved directly from the linked dataset in DataLink. When columns are not used, properties like FirstColumn, LastColumn, and SelectColumn always contain Nil.

See also

TCustomDBGrid.OptionsExtra

  

Contains the extra options enabled for the database grid control.

TCustomDBGrid.DataLink

  

Datalink for the component with event handlers for the linked dataset.

TCustomDBGrid.DataSource

  

Provides access to the dataset displayed in the grid.

TDBGridColumns

  

Implements a collection for columns in a database-aware grid.

TColumn

  

Implements a display column for the TDBGrid control.

TGridColumn

  

Implements a column definition used for tabular data in TCustomGrid.

TField


Version 3.2 Generated 2024-02-25 Home