Hi all,
I have this code for summing up the values in a column of an unknown lenght.With this code the sum will appear in the cell at the bottom of the column at the end of the figures being summed up.Is there a way I could get the sum and place it in another cell on the sheet J1 for example.Here is the code:
Sub test()
lastrow = Worksheets("Sheet1").Cells(Rows.Count, "B").End(xlUp).Row
Range("B" & lastrow + 1).Formula = "=sum(B4:B" & lastrow & ")"
Bookmarks