How do I show the [Start date] and [End Date] on form?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I put down "Between [Start Date] and [End Date]" in a query criteria to
select a range of data and then I create a form to view the result. Is there
any way the FORM can show the dates for "Start date" and "End date" that I
enter when opening the form.

I tried "="From" & [Start Date] & "To" & [End Date]", but it won't work. It
seems it only work on report.

Thank you very much!
 
You say what you tried, but you did not rely tell us where you did this. Is
it an unbound textbox? If so, you are pretty much there, except you put
quotation marks around your equal sign.

= "From " & [Start Date] & " To " & [End Date]


But, I'd format the entry...

= "From " & Format([Start Date],"Medium Date") & " To " & Format([End
Date],"Medium Date")
 
Hi Rick,

I did tried it in unbound textbox in the form. I entered ="From" & [Start
Date] & " To" & [End Date] in control source of the data property without
qoutation mark around equal sign. Also, I tried your entry, too. However,
they both end up showing error message "#NAME?"

Thank you very much for your help!

Ken
 
One option is to create this two parameters as field in the query, and then
refer to the new field in the form

Select TableName.* , [Start Date] As Start_Date,[End Date] As End_Date From
TableName Where FieldName Between [Start Date] and [End Date]

In the form control source write
="From " & [Start_Date] & " To " & [End_Date]
 
Back
Top