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

how to set up query criteria

Status
Not open for further replies.

santosh1

Programmer
Apr 26, 2002
201
US
Hello again,

I stored the query criteria variables into the access table 'TimePeriod'. Then on the select query 'qrySelPlacements', under criteria, I used the build function to set this criteria,

[TimePeriod]![month]
[TimePeriod]![year]

When I run the application, the query is suppose to read the criteria from the table 'TimePeriod', but it isn't, still prompts me for month and year. Am I doing something wrong here? Please let me know. Thankyou.

Santosh
 
It doesn't work that way. You either have to put the query criteria data in global variables and make a function call to them within the criteria row of the query or you can reference a couple of text boxes on a form that has the query values being displayed in them.

But, just storing them in a table will not work in this instance.

Does this help you?

Bob Scriver
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top