Report totals

G

Guest

I'm using Access to build a database at work. I am entering data on a daily
basis from invoices that I wish to sumarize by various periods of time
(daily, weekly, monthly, etc....) so have built From and To parameters into
my query. When running reports, I get #Error for the report totals. If I
build my dates into the query as >=09/01/2007 And <= 09/30/2007 I can get a
total on the report. The query works with the parameters, but not the
report. I am using the =DSum function in the report footer to obtain my
totals. Any ideas what I am doing wrong?
 
A

Allen Browne

Try adding text boxes to the report, bound to the parameters.
Set the Format property to General Date, so Access understands the data
type.

Concatenate the text box names into the DSum() expression.

It would also be a good idea to explicitly declare the paramters in your
query. Choose Parameters on the Query menu (in query design), and enter them
there.

If you can't get that to work, you could use a form to enter the dates, and
then refer directly to the text boxes on the form in your DSum() expression.

--
Allen Browne - Microsoft MVP. Perth, Western Australia

Reply to group, rather than allenbrowne at mvps dot org.

message
news:[email protected]...
 
G

Guest

Your suggestions are helpful, but I'm a beginner at Access and am not sure
how to accomplish what you suggest. Adding the text boxes makes sense to me,
as I would like to have the dates covered print on the report. I'm unsure
how to accomplish binding them to the parameters. When I pull up the data
source options the only choices are the fields in the query. Can you explain
how to bind to the parameters?

Thanks!
 
A

Allen Browne

If the parameter is named StartDate, try adding a text box with Control
Source of:
=[StartDate]

--
Allen Browne - Microsoft MVP. Perth, Western Australia

Reply to group, rather than allenbrowne at mvps dot org.

message
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top