G
Guest
Guest
Dear Mr. Excel,
Say I have a row of numbers, e.g. from A1:A10 and I have a macro as follows:
Cells(1, 1).End(xlDown).Offset(1).FormulaR1C1 = "=SUM(R[-10]C:R[-1]C)"
If the row of numbers changes, say from A1:A7, then the macro doesn't work good anymore!
How can I make the macro work when the row of numbers varies!
Best regards,
Martin
PS The "End(xlDown).Offset(1)" part must stay in the macrocode!
Say I have a row of numbers, e.g. from A1:A10 and I have a macro as follows:
Cells(1, 1).End(xlDown).Offset(1).FormulaR1C1 = "=SUM(R[-10]C:R[-1]C)"
If the row of numbers changes, say from A1:A7, then the macro doesn't work good anymore!
How can I make the macro work when the row of numbers varies!
Best regards,
Martin
PS The "End(xlDown).Offset(1)" part must stay in the macrocode!