Using user selected criteria in a report heading

G

Guest

I have a report that requires the user to enter a beginning and ending date
use by a query. The query works fine. Is their a way to use the dates
entered in a report to indentify the dates included in the report (as
selected by the user)?
 
J

Jeff Boyce

Scott

You did say "a way"...

Create an "order" form with a couple controls to receive begin and end
dates. Revise the query to point at the form for its parameters. Revise
the report to point to the form for the date values. Add a command button
to the form to open the report, after checking to see that the parameter
values have been entered.
 
J

Joan Wild

Scott S. said:
I have a report that requires the user to enter a beginning and ending date
use by a query. The query works fine. Is their a way to use the dates
entered in a report to indentify the dates included in the report (as
selected by the user)?

You can add a textbox to your report's header with this in the control
source:

="From " & [Enter Start Date] & " to " & [Enter End Date]

The [Enter Start Date] and [Enter End Date] in the above would be the exact
same parameter prompts you set up in the query.

An alternative is to create an unbound form with textboxes and a command
button. You would enter the dates in the textboxes, and change your query
to refer to these like Forms!FormName!ControlName. The command button would
open your report.
 

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