Need to use answer from combobox selection as listfillrange for s.

G

Guest

I am creating a complex spreadsheed and need to use the answer from the first
combobox as the listfillrange answer on a second combobox. This would allow
users of the sheet to select a manufacturer and then the second combobox
would let them select the model of equipment made by that manufacturer. It
will not accept the answer cell text as the listfillrange entry. It makes
that answer cell itself as the listfillrange to be used in the dropdown list.
Please help if you have a solution.
 
G

Guest

Not sure exactly what you are trying to do, but believe the below will at
least conceptually get u there.

Private Sub ComboBox1_DropButtonClick()

ComboBox1.AddItem "aaa", ListIndex = 0
ComboBox1.AddItem "bbb", ListIndex = 1
ComboBox1.AddItem "ccc", ListIndex = 2

End Sub
Private Sub ComboBox2_DropButtonClick()

ComboBox2.AddItem "fred", ListIndex = 0
ComboBox2.AddItem "frederic", ListIndex = 1
ComboBox2.AddItem "fredy", ListIndex = 2

If ComboBox1.Value <> "" Then
Dim val As String
val = ComboBox1.Value
ComboBox2.AddItem val
End If

End Sub

regards,
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top