Column Object

Properties   Events   Methods   See Also

Creates a Column in a Grid.

Syntax

Column

Remarks

The number of Columns in a Grid is specified with the Grid's ColumnCount property.

A Column in a Grid can contain data from a field in a table, or the value of an expression. Use the DataSource property to specify the data that appears in the Column.

A Column can also contain controls. Controls are added to a Column in a Grid with the AddObject method in the Init event for the form containing the Grid. Use the column's CurrentControl property to set the active control in the Grid's column. Set the control's ControlSource property to specify the source of the control's data.

Note that headers and controls for a Column cannot be accessed until the Init event for the Grid occurs.

For additional information about creating Columns in a Grid, see the Grid Control topic and Chapter 10, Using Controls, in the Programmer's Guide.