OWLNext    7.0
Borland's Object Windows Library for the modern age
Loading...
Searching...
No Matches
Combo Box Transfer

Combo boxes need to transfer several pieces of information (strings, item data, selected item, and the index of the selected item).

The transfer buffer for combo boxes is a class called TComboBoxData. TComboBoxData has the following data members to hold the combo box information:

Data memberTypeDescription
TComboBoxData::ItemDatasTUint32Array*Contains the item data uint32 for each item in the list box.
TComboBoxData::Selectionchar*Contains the selected string.
TComboBoxData::StringsTStringArray*Contains all the strings in the list box.

TComboBoxData also uses the following member functions to manipulate the combo box information:

Member functionDescription
TComboBoxData::AddStringAdds a string to the Strings array, and optionally selects it.
TComboBoxData::AddStringItemAdds a string to the Strings array, optionally selects it, and

item data to the ItemDatas array.

TComboBoxData::Clear

Clears all data.

TComboBoxData::GetItemDatas

Returns a reference to ItemDatas.

TComboBoxData::GetSelCount

Returns the number of selected items.

TComboBoxData::GetSelection

Returns a reference to the current selection.

TComboBoxData::GetSelIndex

Returns the index of the current selection.

TComboBoxData::GetSelString

Places a copy of the current selection into a character buffer.

TComboBoxData::GetSelStringLength

Returns the length of the currently selected string.

TComboBoxData::GetStrings

Returns a reference to the entire array of strings in the combo box.

TComboBoxData::ResetSelections

Sets the current selection to a null string and sets the index to CB_ERR.

TComboBoxData::Select

Sets a string in Strings to be the current selection, based on an index parameter.

TComboBoxData::SelectString

Sets a string in Strings to be the current selection, based on matching a const char far* parameter.

See Also