I know how to code in order to fill down a column, but I have a few conditions that I can't find out how to implement.
I want to fill down until the last row (that contains any value at all) or the next cell within the column that contains information.
The data looks like this
a 1 2 3 4 5 6 7 8 9 10
1 2 3 4 5 6 7 8 9 10
1 2 3 4 5 6 7 8 9 10
1 2 3 4 5 6 7 8 9 10
1 2 3 4 5 6 7 8 9 10
b 1 2 3 4 5 6 7 8 9 10
1 2 3 4 5 6 7 8 9 10
c 1 2 3 4 5 6 7 8 9 10
d 1 2 3 4 5 6 7 8 9 10
1 2 3 4 5 6 7 8 9 10
1 2 3 4 5 6 7 8 9 10
e 1 2 3 4 5 6 7 8 9 10
1 2 3 4 5 6 7 8 9 10
1 2 3 4 5 6 7 8 9 10
1 2 3 4 5 6 7 8 9 10
1 2 3 4 5 6 7 8 9 10
So as you can see, the code needs to recognize how to stop at b (and not copy over it) when copying down the column. Also the code needs to stop at the last row with values in it when dragging down e.
I've been trying to figure it out to no avail, please help!!!
Previous code:
Yes I do have some code, but it is slow and I would like to figure out something more efficient.
'Sub CopyDown()
Sheets("RAW").Range("A1").Select
For i = 1 To 100
ActiveCell.Copy
ActiveCell.Offset(1, 0).Select
If ActiveCell.Value = vbNullString Then
ActiveCell.Paste
End If
Next i
End Sub'
This one is simple, if your example dataset is used (filling down the existing values to the blanks in Column A.)
(Code Modified)