Copy your dataitem - but without any layout. Then calculate the value in the first loop of the dataitem on the OnAfterGetRecord trigger like suggested above (remember also to copy all filters). When you run the "original" dataitem (with the layout) then you already know the total.
↧