Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 41
Default comboBoxes on a userform

Good Day.

I have done many comboBoxes on a userform, but now I now I need one comboBox
to look at another.

E.G
comboBox 1 has the district listed
comboBox 2 has the Facility listed
When you choice a district in comboBox1, then only the facilities belonging
to that district should show in comboBox 2.
On a sheet I do have the list of all the Districts in one col and list of
districts to Facility in two other col.

Thanks for your help

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,942
Default comboBoxes on a userform

hi
what you described sounds like cascading combos sometimes call dependent
combos. works something like this....
Private Sub ComboBox1_Change()
If Me.ComboBox1.Value = "1" Then
Me.ComboBox2.RowSource = "B5:B6"
Else
Me.ComboBox2.RowSource = "D5:D6"
End If
End Sub
this sample code is for a two option combo box. if you have more options
then add more ifs for the additional options.

regards
FSt1

"LLoyd" wrote:

Good Day.

I have done many comboBoxes on a userform, but now I now I need one comboBox
to look at another.

E.G
comboBox 1 has the district listed
comboBox 2 has the Facility listed
When you choice a district in comboBox1, then only the facilities belonging
to that district should show in comboBox 2.
On a sheet I do have the list of all the Districts in one col and list of
districts to Facility in two other col.

Thanks for your help

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Modify code to Add ComboBoxes instaed of Textbox values on Userform ? Corey Excel Programming 2 January 11th 07 04:59 PM
Userform Comboboxes - need a quick how to.. RogerNZ Excel Programming 1 July 22nd 04 03:05 AM
ComboBoxes Ryan Excel Programming 0 April 14th 04 10:56 PM
Multiple ComboBoxes and TextBoxes on Userform Rich J Excel Programming 6 January 27th 04 07:51 PM
Several comboBoxes on a Userform mor.mic Excel Programming 3 October 1st 03 09:44 PM


All times are GMT +1. The time now is 05:03 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"