Hi,Ive got a matrix,1 2 31 0.00023 0.00000 0.000152 0.00589 0.00000 0.003063 0.00384 0.11011 0.00087Sum x x xThe values in the textbox are based on custom calculations (log(db1field.value etc)), Now I wanted to do a sum at the bottom of each group but SSRS doesnt allow SUM(ReportItems.Textbox.value)So ive written a custom code (below) which then i created a hiden field in the matrix and added the value in each cell to.but the problem with that is, its adding every cell and giving the same value at every 'x' location above.Any ideas on how I would go about retrieving the sum of each grouping instead of all of them?Many ThanksPublic Dim TotalAmount As Double = 0Public Function CalculateRowTotal(ThatValue As Double) As DoubleDim LocalVar as Double = ThatValueLocalVar = Round(ThatValue, 5)IF LocalVar > 1 THENLocalVar = 0ELSEIF LocalVar < 0 THENLocalVar = 0END IFTotalAmount = TotalAmount + (LocalVar)Return LocalVarEnd Function
↧