Where is your subreport located? Are you trying to summarize results that are coming from multiple executions of the subreport? If so, you would need to use shared variables in the subreport, and then use them in the main report where they are accumulated in a second variable.
I'm looking to do the same thing for a report of mine, and I am already using shared variables for a grand total at the end.
Trouble with mine, is that the details that need to be in my subreport come from information derived from subreports in group footers. I currently have one report for the detail, and the summary (which utilises subreports) is in a seperate report. I can't import the summary as a subreport without losing the subreports contained within it.
The only other option i can think of is to create some sort of shared array variable, but that method (if possible) would be messy, cumbersome, prone to error, put a limitation on the report, and it would be generally bad programming style.
Since you can't nest subreports, this calls for a report redesign. Since we have no details on what you are trying to do, it's hard to recommend specifics. Perhaps there is a way to eliminate the subreports in the summary report. Or, if there is a strong rationale for subreports, maybe you could save your current "main" report as a subreport and insert it in the summary report.
I tried to see if I could eliminate the need for subreports, but I couldn't. I like the idea of redesigning so that the main report becomes the subreport, but that would take too much time if it is indeed possible, and I think our client would rather just have two files to choose from rather than pay us lots of money to totally redesign the report.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.