Calculations with subreport in main report footer

marko

Registered User.
Local time
Today, 17:34
Joined
Dec 20, 2002
Messages
24
Hi!

I have a subreport in my main report footer. I would like to get the sum of the subreport values on the main report.
I tried to type the following in the textbox controlsource on main report where I would like to see the total: =sum([subreportname]![textboxname]) but I get an error. Then I tried =sum([reports]![subreportname]![textboxname]) but I get an error again.

How can I get that total on the main report?

Thanks!
 
Marko,

Can't you can get the values right from the source of the subreport (query)?

Greetz
Bert
 
Try this,

[Name of control in the main report which links to the Sub Report].[Report]![Name of control in the sub report]


Sandman
 
Do the calculation in a textbox in the subreport footer, then use the HasData method to display the amount on the main report.
Search here for HasData, there are examples posted
 
Rich said:
Do the calculation in a textbox in the subreport footer, then use the HasData method to display the amount on the main report.
Search here for HasData, there are examples posted

Thank you on your replies everyone!
"Hasdata" works fine when my subreport is in the report footer on main report. But my problem is that I dont know how to get SUM calculation in a textbox on a main report from subreports that are in part# footer on my main form. So subreport are not in page or report footer.
 
Rich said:
Form or report footer?

Sorry about the delay.
"part# footer" is in main report. But it is not in report footer but "part#" has its own footer!
 

Users who are viewing this thread

Back
Top Bottom