Sum Function in Macro

  • Thread starter Thread starter Tim
  • Start date Start date
T

Tim

I need to sum variable length rows in a macro. I use; Cells(ActiveCell.Row
+ 1, ActiveCell.Column).Select and then; ActiveCell.FormulaR1C1 =
"=SUM(R[-54]C:R[-1]C)".

Thanks,
Tim
 
Tim,

Not really sure what the question is but this will sum from row 1 to the
current row

With ActiveCell
Cells(.Row + 1, .Column).FormulaR1C1 = "=SUM(R1C:R[-1]C)"
End With


What exactly do you want to sum?

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)
 
Back
Top