Hello everyone,
As new as one can be to VBA <= well that's me. Looking for a push in the right direction here..
Imagine you have a unique value in column D2, which you want to copy to (D3:D4). You select D2 and double-click the pointer, select 'Copy Cells' in the option menu and I'm done.
What if I have to repeat this action for the entire column D.
So all the empty rows should be filled with a copy from the first unique value that's filled above.
Opening the VBA Module1(Code) and looking at what excel is recording, only shows each separate action:
----
Sub FORMULA()
'
' FORMULA Macro
Range("D2").Select
Selection.AutoFill Destination:=Range("D2:D4"), Type:=xlFillCopy
Range("D2:D4").Select
Range("D5").Select
Selection.AutoFill Destination:=Range("D5:D7"), Type:=xlFillCopy
Range("D5:D7").Select
Range("D8").Select
Selection.AutoFill Destination:=Range("D8:D13"), Type:=xlFillCopy
Range("D8:D13").Select
End Sub
----
How can we create a loop to auto-FillCopy the empty cells with the unique values - within column D?
(Please find image attached)
Thanks in advance!
Bookmarks