"Sum" function as Macro

O

orenfarhi

hi there.
I'm new in this forum.
I want to simulate the button of auto SUM (sigma).
if in cells a1:a10 i have numbers.
in a11 i have the SUM function.
i the next 10 cells i have also numbers.
i want this macro to simulate the auto SUM button so it will calculate
from a12 till the one before him.
Thanks for all helpers. :)
 
S

Simon Lloyd

Not sure what your looking for exactly but this line will sum everythin
in the range you set (i've set it to be A14:E26) in to the cell A12

HTH

Simon

Range("A12").Select
ActiveCell.FormulaR1C1 = "=SUM(R[2]C:R[14]C[4])
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top