Show Total In Subreport On Main Report

  • Thread starter Thread starter Marie
  • Start date Start date
M

Marie

How do you display a total from a subreport on the main report. If it makes
a difference, the total is a total of a calculated field (Qty * Price). Does
the total on the subreport go in the pagefooter or report footer? Say the
total is shown in a texrbox named MyTotal and the subreport control is named
MySubreportControl, what exactly do I put in the control source of a textbox
on the main report to show the total?

Thanks For All Help!

Marie
 
Marie,
Your total control in the subreport should be in the report footer. You can
reference it in your main report with syntax like:
=MySubReportControl.Report!MyTotal
If you expect that the subreport may not return records, you can use:
=IIf(MySubReportControl.Report.HasData, MySubReportControl.Report!MyTotal,
0)

Congrats on asking a clear question. It's nice getting some good information
on your needs and conditions.
 

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

Back
Top