I have a Crystal Report with several subreports. I have a Sum in the Report Footer of two of those reports and a shared numbervar that equals those Sums:
shared numbervar TtlDemand;
TtlDemand := Sum ({Requirement_Detail.DUEQTY_11})
shared numbervar TtlOnOrder;
TtlOnOrder := Sum ({@DueQty});
In the main report I have four Group Footers for the single Group in the report (Group Header and Details are suppressed):
1a (which contains the all the display fields
1b which contains:
shared numbervar TtlDemand;
shared numbervar TtlOnOrder;
1c (suppressed) which contains the reset formulas
and
1d which is blank and is only used to create a space between one group record and the next during output/export
I have it setup this way in order to pass the sums to one of the group footers in the main report because all of the subreports each have a different number of records in them, so leaving the Report footer in the subreport unsuppressed will not help me to keep the sums all on one line in the finished report.
When running the report, for any group that is able to display on one single page, the shared variable displays the correct amount.
However, if the subreport, and thus the group, spans onto 2 or more pages, the shared variable displays 0.00. In the Crystal Reports Preview, if I double-click on that 0.00, it opens up another Preview window of just that group but without all the Report and Page headers/footers; it is just the group. When scrolling to the last page, the shared variable displays the correct amount.
I cannot figure out how to get it to display properly. I have put the reset formulas in the group header, a lower group footer, and even removed them altogether, all to no avail.
I am unsure what other information you might need to assist.
