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

Crosstab Query Misbehaving 1

Status
Not open for further replies.

tomco22

Technical User
Sep 16, 2000
74
US
Is there a trick to get my Crosstab query to read a text box from a form. I am trying to limit the date range to a calendar month in my Crosstab query. It works fine if I hard code the dates but I am striving for dynamic. The following is a date field:

Code:
Criteria: >=([Forms]![frmReports]![txtFirstOfThisMonth]) And <([Forms]![frmReports]![txtFirstOfNextMonth])

I’ve tried having the Crosstab query draw from a another query that has this date range but I get the same message, “The Microsoft Jet database engine does not recognize ‘[Forms]![frmReports]![txtFirstOfThisMonth]’ as a valid field name or expression.” I DO have the reference form open and the text boxes formatted as "Short Date". Any ideas?

Tom
MCSD
I Nab Terrorists
 
Try the following:
In the query design select Parameters from the query menu. Enter both form references and their datatype.

Roy-Vidar
 
thanks RoyVidar! I had to walk out of work yesterday and cool off becuase I was getting so frustrated on this one. Have a twinkler!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top