Dear Tom,
I do not run the report from a Form, I open the Report section and
double-click on the report name, up comes the box asking for the date to use
for the report, I type in the date (mm/dd/yyy Format) and the report is
done.
The report is based on the Query that has as a Criteria: [Select the S/D
Date: mm/dd/yyyy].
From your reply I imagine that I use a Form to run my reports from, one with
a combobox on to select the date, using your crietria statement, is this
correct?
TIA, Colin
> Dear Colin:
>
[quoted text clipped - 27 lines]
>> the table being queried.
>> TIA, Colin.
Tom Ellison - 20 Nov 2005 04:02 GMT
Dear Colin:
Yes, using a form to specify what you want the report to do is generally
much more powerful. I strongly recommend this.
On this form there would probably be a command button to run the report. I
recommend you do one of two things:
- disable the command button if the required selection to run the report
are not available (in the case, if no date has been selected in the combo
box)
- or, when the command button is depressed, check to see that a date has
been selected in the combo box. If it is not, display a message to the user
that the date must be selected before running the report, and do not run the
report. When the user closes the dialog with that warning, place the focus
on the combo box.
This is much better programming.
Tom Ellison
> Dear Tom,
>
[quoted text clipped - 43 lines]
>>> the table being queried.
>>> TIA, Colin.
Sapper - 20 Nov 2005 20:23 GMT
Dear Tom,
Did that, works great.
I made the combo box reference to the same table as the query and get the
listing of dates, but (you knew there was going to be a "but" didn't you?)
the combo box lists all dates even duplicates.
How do I get it to list all dates available once, no duplicates?
Colin.
> Dear Colin:
>
[quoted text clipped - 65 lines]
>>>> the table being queried.
>>>> TIA, Colin.
Tom Ellison - 20 Nov 2005 20:29 GMT
Dear Sapper:
It sounds like you made the Row Source of the combo box to be the table.
Instead, make it a query, and have the query select distinct values of the
date.
Tom Ellison
> Dear Tom,
>
[quoted text clipped - 77 lines]
>>>>> the table being queried.
>>>>> TIA, Colin.
Sapper - 21 Nov 2005 22:37 GMT
Dear Tom,
Yes, after I got my head screwed on right it all came together, as you said
make a query as the source.
It all worked excellent, another trick of the trade I've learnt from this
group.
Thx a lot,
Colin.
> Dear Sapper:
>
[quoted text clipped - 85 lines]
>>>>>> in the table being queried.
>>>>>> TIA, Colin.