Hi Jim28
Like this?The code finds the last row used in column A and performs the loop until it finds it.![]()
Option Explicit Public Sub test() Dim LR As Long Dim i As Long LR = Range("A" & Rows.Count).End(xlUp).Row i = 1 Do Cells(i, 1) = i i = i + 1 Loop Until i = LR + 1 End Sub
John
Bookmarks