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

Passing Variables from form To report

Status
Not open for further replies.

mrweatherbee

Programmer
Jul 5, 2001
11
US
Hi,

This problem seems as though it should be simple to solve, but I just can't get it. Basically, I have a form, with two text boxes where users can enter in a date range (one date in each box...a from and to box). Then when a button is clicked, a report is called up that queries the records within the specified date range. That works fine, but I want to have the date range that the user entered into the text box printed on the report as well, but just can't seem to get it to work? Any help or advice would be greatly appreciated...thanks...
 
You can use an unbound textbox to go out and get the dates. I usually put a little narrative in the control source of the unbound textbox like this:

="For dates between " & [Forms]![MyFormName]![MyStartDate] & " and " & [Forms]![MyFormName]![MyEndDate]

obviously you'll need to change the form and control names to match your scenario. Hope that helps!

Joe Miller
joe.miller@flotech.net
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top