If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
|
Thread Tools | Display Modes |
#11
|
|||
|
|||
Calculating page/report sums using calculated data from subque
rickr wrote:
That definitely did the trick. Thank you ever so much. Sometimes it is the simple things that really cause the most difficulties. I truly appreciate your help. So, for those that may want a solution recap: If you have a report with a sub report, and need to use values from the sub-report in order to calculate total report values, follow this procedu 1. For each sub-report value that needs to be referenced on the main report totals a. Create a text-box and place it on the main detail section, name it something useful like 'col_1_Sum' b. In the Control Source, reference the sub-report data element like so: =IIf([Sub-Report_Name].Report.HasData,Nz([Sub-Report_Name].Report.column1,0),0) c. Set the text-box 'Running Sum' property as necessary (I created 2 text boxes, 1 for the primary group and the second for the 'Over All' option) d. Optional: Make the text-box NOT Visible 2. In the Report Footer, set the text-box where the total is going to be displayed like this (using the text box with Over All running sum): = Sum([col1]) + [col_1_sum] Works like a charm. Nice wrap up summary. Here's hoping a lot of people with the same issue find it when they search for a solution for this problem. -- Marsh MVP [MS Access] |
|
Thread Tools | |
Display Modes | |
|
|