-----Original Message-----
You will need to keep a running sum on each of the totals from the
subreports.
1. Open the subreport in design view.
2. If you don't see a Report Footer section, click Report Header/Footer on
the View menu. Set the Visible property of this section to No if you do not
wish to see it.
3. Add a text box to the report footer section, and give it these
properties:
Control Source =Sum([Profit])
Name txtSumProfit
Format Currency
4. Test. Save. Close the subreport.
5. Open the main report in design view.
6. Add a text box to the same section as the subreport, and set these
properties:
Control Source =IIf([Sub1].[Report].[HasData],
[Sub1].[Report].[txtSumProfit], 0)
Name txtSubTotal
Format Currency
Replace "Sub1" with the name of your subreport control.
Testing the HasData property solves a problem where the control will error
if the subreport has no data (and so referring to the non-existent text box
creates an error).
7. Add another text box beside this one to collect the runing total of the
subreports. The properties will be:
Control Source =[txtSubTotal]
Name txtSubTotalRS
Runing Sum Over All
Format Currency
8. In the report footer, you can now place a text box to show the grand
total. It will be the sum of the Profit field in the main report, plus the
running sum from all the subtotals of the subreports. Set these properties:
Control Source =Sum([Profit]) + [txtSubTotalRS]
Format Currency
--
Allen Browne - Microsoft MVP. Perth, Western Australia.
Reply to group, rather than allenbrowne at mvps dot org.
Hello:
I have a report:
Description Profit
LMOBG0825 $300
and a subreport:
RAMBG0623 $100
JSO0308 $200
I need to show a grand total at the bottom-in this case
$600
Can someone help me please?
.