Quantcast
Channel: Active questions tagged worksheet-function - Super User
Viewing all articles
Browse latest Browse all 926

Excel 2013: VBA to copy formula from one cell to the next

$
0
0

I need to copy a formula from Cell A3 to B3 in Excel, using a button to run below macro:

Sub Copy()    Range("A3").Select    ActiveCell.Offset(0, 1).Formula = ActiveCell.FormulaEnd Sub

Then with every subsequent click of the button, the formula needs to be copied to the next cell in the range(B3:J3) until the whole range is populated. I do not want to fill the range at once with one click of the button, but rather one cell with each click only as this will happen over a period of weeks, therefore one cell to be populated every week.


Viewing all articles
Browse latest Browse all 926

Trending Articles