Skip to main content

TcxLookupComboBoxProperties.ListColumns Property

Specifies the collection of columns displayed within the dropdown window of a lookup editor.

Declaration

property ListColumns: TcxLookupDBGridColumns read; write;

Property Value

Type Description
TcxLookupDBGridColumns

A lookup grid column collection.

Remarks

A LookupComboBox editor displays records from the ListSource datasource within the dropdown window. Records are arranged in columns which can be accessed via the ListColumns collection. You can use the ListColumns property to add/remove columns and access their properties.

A lookup edit column represents a TcxLookupDBGridColumn instance. To bind a column to a datasource field, use its TcxLookupDBGridColumn.FieldName property.

Columns can be added to or removed from the collection both at design time and via code. At design time, a user can work with the ListColumns collection editor in order to add or remove columns from the collection, specify the data source field for each column, change a specific column’s settings, such as width and sorting possibility etc.

Another way of editing the ListColumns collection is to work with the ListFieldNames property. A user can add a column to the collection by adding the name of a new data source field to the ListFieldNames property value. A column can be removed if the name of the corresponding data source field is removed from the ListFieldNames property value.

See Also