AutoGenerateColumns Property

Gets or sets a value indicating whether columns are created automatically when the DataSource or DataMember properties are set.

Syntax

Public Property AutoGenerateColumns As Boolean

Applies To

Grid Object

Data Type

Boolean

Remarks

Columns are automatically generated when this property is set to true and the DataSource or DataMember properties are set or changed.

If you set the DataSource property but set AutoGenerateColumns to false, you must add columns manually. You can bind each added column to the data source by setting the Column.DataPropertyName property to the name of a property exposed by the bound objects.

See Also

DataSource Property, DataMember Property