I have another Problem. I am trying to retrieve an object from my combo box through the tag property but it's not having any of it. I populate my setOfCars as a collection like so
Expand|Select|Wrap|Line Numbers
- foreach (Car car in DBcars)
- {
- car.Tag = car ;
- SetOfCars.Add(car);
- }
Expand|Select|Wrap|Line Numbers
- foreach (Car car in SetOfCars)
- {
- cb_Car.Items.Add(car.Tag);
- }
I then want to grab the selected item in the comboBox as an object. Everything that i have tried is failing miserably. Could anyone suggest how i would go about obtaining the object from the comboBox.