Output reverts to zeros when printing (revisited)
Hi,
I have had an issue with this report for a while now and have spent alot of
time trying to resolve it without any luck.
Basically when I run a report to screen (either via Designer mode or
directly from Report Explorer) it displays totals exactly as would expect
them to be. However if from that screen display I print the report it
displays all zeros for calculated fields and the screen display also reverts
to zeros.
The end-user report is quite complex so I will explain how I have developed
it
1. There are three data pipelines; one master (A) and two child (B & C) in
one-to-many link.
2. There is a report and two sub-reports. Report is connected to A and
sub-reports connected to B and C.
3. Have a number of global declared variables that are used to accumulate
values
4. Sub-reports accumulate totals into declared variables which are then
displayed in the main report (grouped)
5. Calculated Variables then are assigned the values of declared (totalled)
variables
To make this work I had to include the following statement in the
ReportOnFirstPass. Without it values displayed are zero
Variable3.ResetType := veGroupEnd;
Variable3.ResetComponent := Group1;
Im thinking that maybe when printing these variable settings are maybe lost?
Anyway the bottom line is th report displays great with all the correct
figures but when the client goes to print they are left with zeros. Any
help on this greatly appreciated. If need to know anything else please ask.
Thanks
Alex
I have had an issue with this report for a while now and have spent alot of
time trying to resolve it without any luck.
Basically when I run a report to screen (either via Designer mode or
directly from Report Explorer) it displays totals exactly as would expect
them to be. However if from that screen display I print the report it
displays all zeros for calculated fields and the screen display also reverts
to zeros.
The end-user report is quite complex so I will explain how I have developed
it
1. There are three data pipelines; one master (A) and two child (B & C) in
one-to-many link.
2. There is a report and two sub-reports. Report is connected to A and
sub-reports connected to B and C.
3. Have a number of global declared variables that are used to accumulate
values
4. Sub-reports accumulate totals into declared variables which are then
displayed in the main report (grouped)
5. Calculated Variables then are assigned the values of declared (totalled)
variables
To make this work I had to include the following statement in the
ReportOnFirstPass. Without it values displayed are zero
Variable3.ResetType := veGroupEnd;
Variable3.ResetComponent := Group1;
Im thinking that maybe when printing these variable settings are maybe lost?
Anyway the bottom line is th report displays great with all the correct
figures but when the client goes to print they are left with zeros. Any
help on this greatly appreciated. If need to know anything else please ask.
Thanks
Alex
This discussion has been closed.
Comments
OnGroupFooter rather than OnGroupEnd and the problem goes away when
printing. Not sure the reasoning behind this, sounds a little inconsistent
but at least I have the end result.
Thanks