Adding a Date Range On A Report- Please Assist

  • Thread starter Thread starter Ray
  • Start date Start date
R

Ray

I have weekly report that prints out of Access. I have the
query setup to prompt for a date range to access the
report (let's say i want data from 12/22/03 thru
12/26/03). What i want is for the date range i input for
the report to show up in my report's Header (i.e. "Week of
12/22/03 - 12/26/03)... Can anyone assist, any help would
be greatly appreciated.

Thanks,
Ray
 
The easiest way may be to create a print form with unbound
boxes wjere you enter the start and end date, than enter
the text boxes on your report refering to these boxes and
base the report query on these same boxes.
Hope this helps.
Merry Christmas
Fons
 
Ray,

Use the same expression as in your query's parameter prompt within the
control source of an unbound textbox on the report, for example...
="Week of " & Format([Date from?],"mm\/dd\/yy") & " - " & Format([Date
to?],"mm\/dd\/yy")

Alternatively, don't use a parameter query. Instead, put unbound
textboxes on a form for the purpose of the user entering the start and
end dates of the period required, use a reference to these textboxes
in the query criteria of your date field, such as...
Between [Forms]![FormName]![DateFrom] And [Forms]![FormName]![DateTo]
.... and also in the expression on your report, e.g.
="Week of " & Format([Forms]![FormName]![DateFrom],"mm\/dd\/yy") & " -
" & Format([Forms]![FormName]![DateTo],"mm\/dd\/yy")

- Steve Schapel, Microsoft Access MVP
 
Thank you both for your assitance and have a wonderful
Holiday!!!!!!
-----Original Message-----
Ray,

Use the same expression as in your query's parameter prompt within the
control source of an unbound textbox on the report, for example...
="Week of " & Format([Date from?],"mm\/dd\/yy") & " - " & Format([Date
to?],"mm\/dd\/yy")

Alternatively, don't use a parameter query. Instead, put unbound
textboxes on a form for the purpose of the user entering the start and
end dates of the period required, use a reference to these textboxes
in the query criteria of your date field, such as...
Between [Forms]![FormName]![DateFrom] And [Forms]! [FormName]![DateTo]
.... and also in the expression on your report, e.g.
="Week of " & Format([Forms]![FormName]! [DateFrom],"mm\/dd\/yy") & " -
" & Format([Forms]![FormName]![DateTo],"mm\/dd\/yy")

- Steve Schapel, Microsoft Access MVP


I have weekly report that prints out of Access. I have the
query setup to prompt for a date range to access the
report (let's say i want data from 12/22/03 thru
12/26/03). What i want is for the date range i input for
the report to show up in my report's Header (i.e. "Week of
12/22/03 - 12/26/03)... Can anyone assist, any help would
be greatly appreciated.

Thanks,
Ray

.
 
Back
Top