Home |
Search |
Today's Posts |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Chip, Tom.. thanks for your help, it worked great.
the second part was to have an item be removed from all the other combo boxes once it was selected from another one. this was complicated byt he fact that there was no way to know in what order the comboboxes would be used. This is how i ended up doing it... basically storing the list index of the selection into a variable, then making sure that the other comboboxes didnt have count of zero (since i clear the combobox list after a choice is made), then removing the corresponding list index. This is for the first box, the other five are exactly the same, with the exception of combobox referances of corse: Private Sub StatBox1_Click() ' Lockes the stat choice in, and removes it ' from the other comboboxes Dim strStat As String Dim X As Integer X = Me.StatBox1.ListIndex 'MsgBox X strStat = Me.StatBox1.Value Me.StatBox1.Clear Me.StatBox1.Value = strStat Me.StatBox1.Locked = True Call FindStat(Me.StatBox1.Value, Me.stat1.Value) If (Me.StatBox2.ListCount 0) Then Me.StatBox2.RemoveItem (X) End If If (Me.StatBox3.ListCount 0) Then Me.StatBox3.RemoveItem (X) End If If (Me.StatBox4.ListCount 0) Then Me.StatBox4.RemoveItem (X) End If If (Me.StatBox5.ListCount 0) Then Me.StatBox5.RemoveItem (X) End If If (Me.StatBox6.ListCount 0) Then Me.StatBox6.RemoveItem (X) End If End Sub |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Getting Combo boxes to change options based on other Combo boxes. | New Users to Excel | |||
multiple combo boxes | Excel Discussion (Misc queries) | |||
Multiple combo boxes with unique duplicates showing only | New Users to Excel | |||
Problem Adding new Combo Boxes | Excel Discussion (Misc queries) | |||
multiple combo boxes | Excel Discussion (Misc queries) |