I want to add values to combobox in C++ builder 6. I know I can add string to combobox by string list editor.
For example, I have added this list to combobox:
car
ball
apple
bird
I want behind each text, it has their own value, so I can get the value rahter than the text when user selected a text. Just like HTML select.
But when I try to add value to each text:
ComboBox1->Items->Values[0] = "mycar";
ComboBox1->Items->Values[1] = "aball";
etc...
it will add more text to the list, like
car
ball
apple
bird
0=mycar
1=aball
This is not what I want. I don't want the extra text to add to the list. So, how can I add values to each text properly, and get the value?