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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Combo List Creation based on another field

Status
Not open for further replies.

DreamerZ

Programmer
Jul 11, 2001
254
US
I want to have a combo list created based on a date field.

I have a record with a date (short date currently, but can be anything). If that date is a "Thursday" (i.e. 8/8/02), then I want to have a combo list created that shows only those people available on Thursday. If they said they weren't available on Thursday, then they don't appear in the list. Essentially, if person#1 says they are available on Thursday, and the date scheduling for is a Thursday, then show person#1 on the list. If it's not a Thursday, don't show person#1.

I imagine I'd have the combo box based on a query so I've tried using the various functions Day(), Date(), DatePart(), etc. to no avail.

Can this be done? If so, where and/or what am I missing?

Thx,

DreamerZ
 
Hiya,

You can populate a combo or list via it's Row Source property.

In the Row Source, you can use a query that returns the values that you want to display in the combo.

Produce a query that gives you the results, then use it in the Row Source property of the combo.

Regards,

Darrylle "Never argue with an idiot, he'll bring you down to his level - then beat you with experience."
 
Yes, thank you. I knew that. I'm having difficulty creating the query.

Anyone else?
 
From what I can see you are going to have to create an availablity table. This table would have list each person and date available. This table would also have to be maintained (you could delete old records though to control the size of your database as they would not be required the past the date you are scheduling. Then for the row source you could say select all employees that have a date = today.

Nick
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top