combo box data changes based on previous combo box

D

Damion

Here's the example:

Combo box number #1 has two choices - month or day...

When I select "month" from combo box #1... I want Combo Box #2 to
pull from a table that has "January, February, March, etc."

However, if Combo Box #1 has "day" select....

Combo Box #2 shows "Monday, Tuesday, Wednesday, etc.".

Anyone know how to do this?


Anotehr workaround if this is not possible would be... if I could have
all choices in combo box #2, and filter which ones show up in the the
list based on what is selected in combo box #1.

Thanks for the help!

Damion
 
F

fredg

Here's the example:

Combo box number #1 has two choices - month or day...

When I select "month" from combo box #1... I want Combo Box #2 to
pull from a table that has "January, February, March, etc."

However, if Combo Box #1 has "day" select....

Combo Box #2 shows "Monday, Tuesday, Wednesday, etc.".

Anyone know how to do this?

Anotehr workaround if this is not possible would be... if I could have
all choices in combo box #2, and filter which ones show up in the the
list based on what is selected in combo box #1.

Thanks for the help!

Damion

If those are the only choices, the name of a month or the name of a
day, then set the Combo2 RowSourceType property to Value List
Leave the Combo2 RowSource blank.

Code the Combo1 AfterUpdate event:

If Me!Combo1 = "Month" Then
Me!Combo2.RowSource = "'January';'February';'March'; 'etc...' "
Else
Me!Combo2.RowSource = "'Monday';'Tuesday';'Wednesday'; 'etc....' "
End If
 

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