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 adds item data to the ItemDatas array.
TComboBoxData::ClearClears all data.
TComboBoxData::GetItemDatasReturns a reference to ItemDatas.
TComboBoxData::GetSelCountReturns the number of selected items.
TComboBoxData::GetSelectionReturns a reference to the current selection.
TComboBoxData::GetSelIndexReturns the index of the current selection.
TComboBoxData::GetSelStringPlaces a copy of the current selection into a character buffer.
TComboBoxData::GetSelStringLengthReturns the length of the currently selected string.
TComboBoxData::GetStringsReturns a reference to the entire array of strings in the combo box.
TComboBoxData::ResetSelectionsSets the current selection to a null string and sets the index to CB_ERR.
TComboBoxData::SelectSets a string in Strings to be the current selection, based on an index parameter.
TComboBoxData::SelectStringSets a string in Strings to be the current selection, based on matching a const char far* parameter.

See Also