Re: Still Hoping for help with a Query problem

From: SteveS (sanfu)
Date: 11/10/04


Date: Tue, 9 Nov 2004 21:00:01 -0800

Are you using a form to enter the start and end dates?

In the header of the report you could put two unbound text boxes. Change the
label for the first text box to "Between". Set the Control Source for the
text box to the text box on the form that has the start date:

= Forms!frmName.StartDate

Set the label for the second text bot to "and" and the Control Source to the
end date:

= Forms!frmName.EndDate

Adjust the spacing and you are done. Remember, the form where you entered
the dates must be open.

Another way is to create an unbound text box and make the width as wide as
the report. Set the "Text Align" property of the text box to "Center". The
Control Source would be:

= "Between " & Forms!frmName.StartDate & " and " & Forms!frmName.EndDate

In both cases you could format the date using:

Format(Forms!frmName.StartDate, "mmm, d, yyyy")

Change frmName to the name of your form and the names of the controls to
whatever you named them.

If you used a pop-up parameter box (did not use a form to get the dates),
you could use the DMax() and DMin() functions to get the max and min dates
from the recordset, substituting the DMax() function for
"Forms!frnName.controlName" in the Control Source of the text boxes.

You could also write a custom function to get the dates from a recordset and
put them in the header.

Fun, huh?

Steve
--------------------------------
"Veni, Vidi, Velcro"
(I came; I saw; I stuck around.)

"Don Sealer" wrote:

> One final thing Steve, how would I show the dates in the report header?
> Don............



Relevant Pages

  • RE: writing records to a table
    ... It is an access report where the control source is the form. ... "Shari" wrote: ... The me.v fields are the unbound and the me. ... In the bound text box I have the control source set to table name. ...
    (microsoft.public.access.forms)
  • Clarification: Re: 6 Tables, 1 Report, W/O 6 Qrys
    ... the same report kicked off by six different buttons. ... the unbound text boxes and go from there. ... This would let the query deal with only one set of values ...
    (microsoft.public.access.reports)
  • Re: For Duane Hookum
    ... >> PrintDeep in a table and made sure this is in the control source for the ... >> report, although its not actually shown as a field on the report. ... Ive set the text box in which I put the code to ... >> What this actually produces is two rows of tiny boxes. ...
    (microsoft.public.access.reports)
  • Re: Report how many old entrys I got.
    ... > In the detail section of your report, add two unbound text boxes and set ...
    (microsoft.public.access.reports)
  • 6 Tables, 1 Report, W/O 6 Qrys
    ... would be to add a set of unbound text boxes to the form, ... information is copied into the unbound text boxes. ... Your query for the envelop report would then pull the ...
    (microsoft.public.access.reports)