Range("A1").End(xlDown).Select Dim lastcell As Integer lastcell = ActiveCell.Row
for row = 1 to lastcell
process
next