Removing a value from combobox

najirm

Newcomer
Joined
Jan 7, 2012
Messages
1
I've two combo boxes listed with same values from the database.

If I select a value from the first combo box, that value should not be listed in the second combo box.

Code:
[U]ComboBox1[/U]             [U] ComboBox2[/U]
One                   One
Two                   Two
Three                 Three
Four                   Four
Five                   Five

If I select 'Three' from the ComboBox1, the value 'Three' should not be listed in ComboBox2 while making a selection from ComboBox2.
 
Do you mean combo boxes or list boxes.
if you do mean combo boxes then do something like
If ComboBox1.Text = ComboBox2.text Then combobox2.text = "four"


if that is not helpful then can you please expand on your problem and what you need it to do (why should it do what you want it to do)
 
idk but try this:

put it in the combobox1 text changed bit
Code:
combobox2.items.remove(combobox1.text)
 
Back
Top