OWLNext 7.0
Borland's Object Windows Library for the modern age
|
TComboBox has two constructors.
The first takes the seven parameters commonly found in a control object constructor (a parent window, a resource identifier, the control's x, y, h, and w dimensions, and an optional module pointer), and also style and maximum text length parameters. This constructor is declared like this:
All combo boxes have the styles WS_CHILD, WS_VISIBLE, WS_GROUP, WS_TABSTOP, CBS_SORT (to sort the list items), CBS_AUTOHSCROLL (to let the user enter more text than fits in the visible edit area), and WS_VSCROLL (vertical scroll bar). The style parameter you supply is one of the Windows combo box styles CBS_SIMPLE, CBS_DROPDOWN, or CBS_DROPDOWNLIST. The text length specifies the maximum number of characters allowed in the edit area.
The second TComboBox constructor lets you create an ObjectWindows object that serves as an alias for an existing combo box. This constructor looks like this:
The following lines show a typical combo box constructor call, constructing a drop down list combo box with an unsorted list: