Macro Code Question for Newbe

  • Thread starter Thread starter DataMan
  • Start date Start date
D

DataMan

Scenario:
I have a worksheet that has Column A and Column B, each containing 10
rows of data, that need to be added together and their sum displayed in
column C.

I want to copy this formula in Column C 10 rows down.

I want to write a macro that will do this but I want the macro to be
able to do the same operation in a file that would have any number or
rows to be added. I do not want to have this formula copied to all the
rows in Column C. Just the rows that have data to be added.

How would I code this?
 
There are many way to do that. Here's one:

Range("B1", Range("B1").End(xlDown)).Offset(0, 1).FillDown
 
Back
Top