My group total is an expression which subtracts the last [Hours1] value from the first [Hours1] value of the group [EquipmentName1] of the dataset “dataset1.
I need a Grand Total the group expression totals for each piece of equipment
I am unable to use the same formula of subtracting last [Hours1] value from the first [Hours1] value of the dataset “dataset1” because.
If I had 2 pieces of equipment, say Equipment1 and Equipment2:
Equipment1 last [Hours1] = 10000 and first [Hours1] = 9500
Equipment2 last [Hours1] = 10500 and first [Hours1] = 10000
If I used the formula of subtracting last [Hours1] value from the first [Hours1] value of the dataset "dataset1" the formula would be 10500 – 9500
However, I want:
(10000 - 9500) + (10500 - 10000) = Grand Total
Below is an attempt to draw part of my table
|_[Hours1]_| = Fields!Hours1.Value
(e.g. 9500)
|___Expr___| = Last(Fields!Hours1.Value) - First(Fields!Hours1.Value)
(e.g. 10000 - 9500 = 500)
|__________| = I need to total the value of Expr for all pieces of equipment
You need to use some custom code to achieve that.
Go to
Report -> Report Properties -> Codeand typeThen on the textboxes you need to call the accumulate function
And on the Grand Total textbox you call the get total function