View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.misc
Toppers Toppers is offline
external usenet poster
 
Posts: 4,339
Default Dynamic dropdowns

I created 4 named ranges "List1" to "List4": "List1" had values 1,2,3.

The following code then set Combobox2 to reference the correct named range.

Hope you can adapt to your needs

Private Sub ComboBox1_Change()
ComboBox2.RowSource = "List" & ComboBox1.Value
End Sub

Private Sub UserForm_Initialize()
ComboBox1.RowSource = "List1"
End Sub

HTH

"gramps" wrote:

Hi

-- What I need is in auserform a way of selecting a value from a dropdown
list and depending on the result 1 of 3 different lists of data being loaded
into a second dropdown list box in the same userform. I have seen
http://www.xldynamic.com/source/xld.Dropdowns.html But cannot see how to
incorporate this into a userform presumably via the Row Source property.
Many thanks.