Overview
Less than 1 minute
Overview of TDataComboBoxEh control
TDataComboBoxEh component is designed to display and select a value from a list.
The components support two operating modes:
- Simple Dropdown List: A basic dropdown list for selecting items.
- Lookup List: A list that maps displayed values to underlying data keys.
Both modes can operate with or without data binding (using DataSource/DataField) (for TDataComboBoxEh).
List Item Sources
The dropdown list items can be sourced in two ways:
External List
To connect an external list of values, use the following property:
- ListSource: TComponent – Supports binding to a
TDataSourceorTDataSetobject.
Built-in List
For manually defining values, use the following property:
- ListItems: TStrings – A collection of strings displayed in the dropdown list.
Data Binding
To link the component to a data source, use the following properties:
- DataSource: Specifies the data source.
- DataFieldName: Specifies the field name in the data source.
Configuration by Mode
- External List:
- Simple List Mode: Populate the
ListSourceandListFieldNameproperties. - Lookup Mode: Populate the
ListSource,ListFieldName, andListKeyFieldNameproperties.
- Simple List Mode: Populate the
- Built-in List:
- Simple List Mode: Populate the
ListItemsproperty with strings to be displayed in the list. - Lookup Mode: Populate the
ListItemsproperty with strings in the format:Key|Displayed Value.
- Simple List Mode: Populate the
