Date Criteria pulled from Calander

S

Sharon

Is there a way to use the dates chosen from a pull down calander for criteria
to run a query?
 
C

Conan Kelly

Sharon,

Where is your pull down calendar? Is it on a form? Is this pull down calendar populating a control on the form?

If so, then Yes, I think so.

Set your criteria to something like this:

# & [forms]![Name of your form]![Name of date control] & #

If you are searching for a range of dates, then you would do something like this:

Between # & [forms]![Name of your form]![Name of StartDate control] & # and # & [forms]![Name of your form]![Name of EndDate
control] & #

I hope this helps,

Conan Kelly
 
S

Sharon

To answer your quetion: This is in a form that has a query to pull "between"
dates.

I tried this by entering the criteria in the query. I get the error that it
is not date format. Any suggestions.


Conan Kelly said:
Sharon,

Where is your pull down calendar? Is it on a form? Is this pull down calendar populating a control on the form?

If so, then Yes, I think so.

Set your criteria to something like this:

# & [forms]![Name of your form]![Name of date control] & #

If you are searching for a range of dates, then you would do something like this:

Between # & [forms]![Name of your form]![Name of StartDate control] & # and # & [forms]![Name of your form]![Name of EndDate
control] & #

I hope this helps,

Conan Kelly




Sharon said:
Is there a way to use the dates chosen from a pull down calander for criteria
to run a query?
 

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