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!

Print Set Date Range on Report

Status
Not open for further replies.

sandingdude

IS-IT--Management
Jun 26, 2002
109
US
Right now I have a report that has a date field. After you open the report a window will popup asking me what the from date and what the to date is? Then the report will open. How can I print what date I put in as the from and to date on the report?

Thx
 
the popup box, is that the built in one that comes up for a parameter query?
if so, then you can't easily reference them...

it'd be best if you put the start and end date onto a form somewhere, and then referenced those in your report. Then you can access the dates easily...
 
You can refer to a date range from the underlying query if you're using a parameter query. In the report, create 2 unbound text boxes. Set the data sources equal to the parameter query's prompt. For example:
Query1 is filtered by pickup_dt
I place pickup_dt in the query 2 times. The first criteria is >=[Enter Start Date]and the second is <=[Enter End Date]

On the report: txt_stDate has a control source of =[Enter Start Date] and txt_endDate has a control source of =[Enter End Date]

I run the report & enter the prompted dates, they appear on the report as I entered them. (Although using a form is probably a better method, this will work) I hope this helped.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top