Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Static data cascading combo box maybe?

Status
Not open for further replies.

compnet

IS-IT--Management
Sep 19, 2007
4
GB
Hi Guys
I need a bit of help with what I expect is a simple issue, but I cant see a solution even after spending hours on Google looking.

Regarding Static Data Cascading Combo box

I dont want to fetch data from tables to display in the combo boxes just static set options. Let me Explain.

We have a database that organises orders and deliveries for an AVON Rep.

A customer selects when they would like deleivery and we put that in the system currently with two combo boxes, Dayoftheweek and timeoftheday, fairly simple they consist of;

Dayoftheweek=
Sunday
Monday
Tuesday
Wednesday
Thursday
Friday
Saturday

And
Timeoftheday=
Morning
Afternoon
Evening

They are put in the customer table as its updated for the AVON campaign they order on, via two simple combo boxes, This required two distinct actions, not very elegant really.

I was hoping to use a cascading combo box that would show the timeoftheday when a dayoftheweek is clicked on. Like;

Tuesday Morning
Afternoon
Evening


and they would then be updatedinto the table when the timeoftheday is clicked.

It would appear to be almost impossible without adding tables and writebacks and requeries and on and on.

Any thoughts please.
Jerry.
 
I quess you have two UNbound comboboxes. I don't know why you want a cascading effect when it seems all the days would have the same timeoftheday. But that's up to you. To do a cascading effect, see:
faq702-4289

Also after the requery statement, you can put
Me![comboboxname].DropDown

If your form is based on the table containing the fields to store both combo selections, then just set their Control Source to the appropriate field.
 
How are ya compnet . . .

In the [blue]AfterUpdate[/blue] event of [blue]Dayoftheweek[/blue], set focus to [blue]timeoftheday[/blue] and dropdown the list:
Code:
[blue]   Me!timeoftheday.SetFocus
   Me!timeoftheday.Dropdown[/blue]
[blue]Your Thoughts? . . .[/blue]

Calvin.gif
See Ya! . . . . . .

Be sure to see thread181-473997 [blue]Worthy Reading![/blue] [thumbsup2]
Also faq181-2886 [blue]Worthy Reading![/blue] [thumbsup2]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top