MS Access report sections challenge

58 Views Asked by At

Thank you for reading

I have a subreport that lists a number of purchase orders (POs) and displays the total of the orders in the footer detail section of the subreport.

The subreport is locayes within the Detail section of the main report.

In the main report; right before the subreport I have an amount (control) that is the allowance for a client (clients cannot order more than a given amount every month).

So I have the allowance and the total of POs. I want to see the balance (Allowance minus Total of POs) in the "balance" control in the footer section of the detail of the main report but I don't know how to reference the control that hosts the total of POs.

1

There are 1 best solutions below

0
On

You can certainly reference controls in subforms/subreports. Though site here uses forms, the same concept applies to reports.

Specifically for your situation. Add a Balance textbox control in header or footer of main report with following control source expression (pay heed to exclamation and period markers):

=[Allowance] - [Reports]![yourmainrptname]![yoursubrptcontrolname].[Report]![yoursubrptfooterPOstotalcontrolname]