A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » New Users
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

"Between" "and" parameters access. How?



 
 
Thread Tools Display Modes
  #1  
Old September 28th, 2004, 05:46 PM
rleblanc
external usenet poster
 
Posts: n/a
Default "Between" "and" parameters access. How?

I have several reports which ask for a "Start Date" and an "End Date" for
use in determining the period of time the report is to show data for. For
this I use the "Between" and "and" function to request from the user what
period of time to display data for.

However, I would like to be able to show at the top of the report the period
covered by the report such as:

Report for start date: mm/dd/yyyy to: mm/dd/yyyy

How do I access the "Start Date" and "End Date" which were entered as part
of a select query? Does Access have a special name for these values? How can
these parameters be accessed for use in the report?

Thanks


  #2  
Old September 28th, 2004, 05:58 PM
Roger Carlson
external usenet poster
 
Posts: n/a
Default

You would be doing yourself a big favor if you created a form which had
textboxes for entering the start and end dates. Then have a button on the
form that opens the report. The query behind the report would reference the
form for their values, then you can also reference the form in a textbox on
the report for the same values.

On my website (www.rogersaccesslibrary.com) is a small Access sample
database called: "ParaQuerySelect2k.mdb", which illustrates how.

--
--Roger Carlson
Access Database Samples: www.rogersaccesslibrary.com
Want answers to your Access questions in your Email?
Free subscription:
http://peach.ease.lsoft.com/scripts/...UBED1=ACCESS-L

"rleblanc" noone@somewhere wrote in message
...
I have several reports which ask for a "Start Date" and an "End Date" for
use in determining the period of time the report is to show data for. For
this I use the "Between" and "and" function to request from the user what
period of time to display data for.

However, I would like to be able to show at the top of the report the

period
covered by the report such as:

Report for start date: mm/dd/yyyy to: mm/dd/yyyy

How do I access the "Start Date" and "End Date" which were entered as part
of a select query? Does Access have a special name for these values? How

can
these parameters be accessed for use in the report?

Thanks




  #3  
Old September 29th, 2004, 02:28 AM
AlCamp
external usenet poster
 
Posts: n/a
Default

You can refer to the parameter values on a report by just using the
parameter...
In this case the [Start Date] parameter can be displayed on the report by
using a control with = [Start Date].
Or concatenate for a better look...
= "Between " & [Start Date] " and " & [End Date]
would display as Between 1/1/04 and 2/1/04
Use them just like a table field...
hth
Al Camp

"rleblanc" noone@somewhere wrote in message
...
I have several reports which ask for a "Start Date" and an "End Date" for
use in determining the period of time the report is to show data for. For
this I use the "Between" and "and" function to request from the user what
period of time to display data for.

However, I would like to be able to show at the top of the report the

period
covered by the report such as:

Report for start date: mm/dd/yyyy to: mm/dd/yyyy

How do I access the "Start Date" and "End Date" which were entered as part
of a select query? Does Access have a special name for these values? How

can
these parameters be accessed for use in the report?

Thanks




  #4  
Old September 29th, 2004, 02:49 PM
Van T. Dinh
external usenet poster
 
Posts: n/a
Default

I think there is a missing ampersand. Try:

= "Between " & Format([Start Date], "mm/dd/yyyy") &
" and " & Format([End Date], "mm/dd/yyyy")

(typed as one line in Access)

--
HTH
Van T. Dinh
MVP (Access)


"AlCamp" wrote in message
...
You can refer to the parameter values on a report by just using the
parameter...
In this case the [Start Date] parameter can be displayed on the report

by
using a control with = [Start Date].
Or concatenate for a better look...
= "Between " & [Start Date] " and " & [End Date]
would display as Between 1/1/04 and 2/1/04
Use them just like a table field...
hth
Al Camp



  #5  
Old September 29th, 2004, 07:16 PM
rleblanc
external usenet poster
 
Posts: n/a
Default

Thanks! This works great!

I just set up two text control boxes, and used the lables for the text box
for text as follows:

From start date: mm/dd/yyyy to: mm/dd/yyyy

And put "StartDate" and "EndDate" in the text boxes themselves. This worked
out perfectly!

Thanks again!



"AlCamp" wrote in message
...
You can refer to the parameter values on a report by just using the
parameter...
In this case the [Start Date] parameter can be displayed on the report
by
using a control with = [Start Date].
Or concatenate for a better look...
= "Between " & [Start Date] " and " & [End Date]
would display as Between 1/1/04 and 2/1/04
Use them just like a table field...
hth
Al Camp

"rleblanc" noone@somewhere wrote in message
...
I have several reports which ask for a "Start Date" and an "End Date" for
use in determining the period of time the report is to show data for.
For
this I use the "Between" and "and" function to request from the user what
period of time to display data for.

However, I would like to be able to show at the top of the report the

period
covered by the report such as:

Report for start date: mm/dd/yyyy to: mm/dd/yyyy

How do I access the "Start Date" and "End Date" which were entered as
part
of a select query? Does Access have a special name for these values? How

can
these parameters be accessed for use in the report?

Thanks






  #6  
Old October 2nd, 2004, 06:07 PM
AlCamp
external usenet poster
 
Posts: n/a
Default

Yep... a typo for sure...
Thanks Van,
Al Camp

"Van T. Dinh" wrote in message
...
I think there is a missing ampersand. Try:

= "Between " & Format([Start Date], "mm/dd/yyyy") &
" and " & Format([End Date], "mm/dd/yyyy")

(typed as one line in Access)

--
HTH
Van T. Dinh
MVP (Access)


"AlCamp" wrote in message
...
You can refer to the parameter values on a report by just using the
parameter...
In this case the [Start Date] parameter can be displayed on the

report
by
using a control with = [Start Date].
Or concatenate for a better look...
= "Between " & [Start Date] " and " & [End Date]
would display as Between 1/1/04 and 2/1/04
Use them just like a table field...
hth
Al Camp





 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 04:44 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.