Grand total not working

G

Guest

Hello! Need help adding a grand total in a report that is already set up with
sub- totals...I am adding a formula for the grand total of the sub-totals but
it keeps adding it as a parameter value? Don't know what I'm doing wrong?
 
J

Jeff Boyce

You didn't provide any specifics about the formula/approach you are using,
so the following is a general observation...

If you have a sub-report (?sub-totals are ?where??), a grand total in the
main report needs to refer to the sub-report's fields.

Regards

Jeff Boyce
Microsoft Office/Access MVP
 
G

Guest

If the subtotals are in a group footer (or header) in the report then you
simply need to repeat the expression (not formula, that's a spreadsheet
concept) which is used as the ControlSource of the text box in the group
footer as the ControlSource property of a text box in the report footer, e.g.
if summing NetPrice * 1+TaxRate fields to give a gross price subtotal then
the ControlSource for the grand total would be exactly the same:

=Sum([NetPrice]*(1+[TaxRate]))

The reason it didn't work the way you tried it is that you cannot reference
one computed control in another computed control, you have to go back to
square one and use the original expression again.

Ken Sheridan
Stafford, England
 
G

Guest

Sorry for posting again! I;m new to posting and threading...but I followed
your advice I believe and the parameter value still keeps popping up. This is
what I did:

'Grand sum' as a label
Text box reads =Sum([text139]+[text 141]+[text143]+[text145])

And the current sub-total sum that works reads =[text139]+[text
141]+[text143]+[text145]

So when i want to run the report the parameter value asks for the dates, the
contractor, and now it asks for an entry of text 139, text 141...etc. plus it
does not give a grand total.

Thank you for your help!

Ken Sheridan said:
If the subtotals are in a group footer (or header) in the report then you
simply need to repeat the expression (not formula, that's a spreadsheet
concept) which is used as the ControlSource of the text box in the group
footer as the ControlSource property of a text box in the report footer, e.g.
if summing NetPrice * 1+TaxRate fields to give a gross price subtotal then
the ControlSource for the grand total would be exactly the same:

=Sum([NetPrice]*(1+[TaxRate]))

The reason it didn't work the way you tried it is that you cannot reference
one computed control in another computed control, you have to go back to
square one and use the original expression again.

Ken Sheridan
Stafford, England

Jes in TX said:
Hello! Need help adding a grand total in a report that is already set up with
sub- totals...I am adding a formula for the grand total of the sub-totals but
it keeps adding it as a parameter value? Don't know what I'm doing wrong?
 
J

Jeff Boyce

Aha! You are referring to the controls on your report (e.g., text139,
text141, ...). Access will not look inside those controls to see the
values.

Instead, whatever field each of those controls is based on, you will need to
include that underlying FIELD in your grand total expression, not the
control's name.

Regards

Jeff Boyce
Microsoft Office/Access MVP

Jes in TX said:
Sorry for posting again! I;m new to posting and threading...but I followed
your advice I believe and the parameter value still keeps popping up. This
is
what I did:

'Grand sum' as a label
Text box reads =Sum([text139]+[text 141]+[text143]+[text145])

And the current sub-total sum that works reads =[text139]+[text
141]+[text143]+[text145]

So when i want to run the report the parameter value asks for the dates,
the
contractor, and now it asks for an entry of text 139, text 141...etc. plus
it
does not give a grand total.

Thank you for your help!

Ken Sheridan said:
If the subtotals are in a group footer (or header) in the report then you
simply need to repeat the expression (not formula, that's a spreadsheet
concept) which is used as the ControlSource of the text box in the group
footer as the ControlSource property of a text box in the report footer,
e.g.
if summing NetPrice * 1+TaxRate fields to give a gross price subtotal
then
the ControlSource for the grand total would be exactly the same:

=Sum([NetPrice]*(1+[TaxRate]))

The reason it didn't work the way you tried it is that you cannot
reference
one computed control in another computed control, you have to go back to
square one and use the original expression again.

Ken Sheridan
Stafford, England

Jes in TX said:
Hello! Need help adding a grand total in a report that is already set
up with
sub- totals...I am adding a formula for the grand total of the
sub-totals but
it keeps adding it as a parameter value? Don't know what I'm doing
wrong?
 

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