inline SUM to accumulate values
I need to accumulate a value inline. Example:
number: value (accumulated value)
1: 10 (10)
2: 15 (25)
3: 5 (30)
the fields: number and value are placed on a DetailDataBand1 with DetailData1.
When placing [SUM(<value>, DetailData1)] for the accumulated value on the DatailDataBand, nothing is displayed.
How to solve?
number: value (accumulated value)
1: 10 (10)
2: 15 (25)
3: 5 (30)
the fields: number and value are placed on a DetailDataBand1 with DetailData1.
When placing [SUM(<value>, DetailData1)] for the accumulated value on the DatailDataBand, nothing is displayed.
How to solve?
Comments
at the beginning of report script page declare var of required type.
ie
var
myaccumvar: integer;
this creates a variable which is globall to all report events.
in obp event of masterband initialize to 0
myaccumvar := 0;
in obp of detailband or obp event of memo
myaccumvar := myaccumvar + whatever;
in memo use [myaccumvar] for display.