Crystal report, display Sum in Group Header.

imranIBM

Newcomer
Joined
May 17, 2005
I couldn't find any category for crystal reports so I am writting here. Sorry for that.

In my report each row displays the maximum { Max(field) } value of a set of feilds using Max function. These rows are in each Group.

I want to display the sum of these row in the Group Header at the top of each group. The Sum() function doesnot allow me to do the sum of Max fields, so I am adding each row's value to a variable and displaying that variable in the Group Header.
Variable x;

x = x + Maxfield;

But it displays only the value of the first row.

Correct result:

Group 1 Total - 5 (Sum of 3 + 2)

Row#1....3
Row#2....2


My incorrect result:

Group 1 Total - 3 (First row value)

Row#1....3
Row#2....2

can anyone please help.
 

TMI

Newcomer
Joined
Oct 15, 2003
In Crystal Reports you can insert a summary object that will return the sum of which ever field you wish. You can find it on the insert tool bar and under teh Insert pull down menu.
 
Top Bottom