Hi all,

I have struggled with this for a couple of days now and have gone cross eyed looking at it.

I am using the following macro to total all amount between blank rows.

Sub total()
Dim StartRow As Integer
Dim EndRow As Integer

StartRow = 13
EndRow = Range("D65536").End(xlUp).Offset(1, 0).Row
For i = StartRow To EndRow
If Cells(i, "D") = "" And i > StartRow Then
Cells(i, "D").Formula = "=SUM(D" & StartRow & ":D" & i - 1 & ")"
StartRow = i + 1
End If
Next
End Sub
It totals the amounts in column D. and places the SUM in column D. What I would like is to place the SUM into column I. E.g. When =SUM(D20:D55) instead of the answer being placed in D56 I would like it to be place in I55. See attached.

Do you think this is possible?

Many thanks in advance for your assistance.

Drew

TEST.XLS