Sub loopDelete()
Dim upperLim As Integer
Dim count As Integer
upperLim = Application.InputBox("How many loops?")
count = 1
For count = 1 To upperLim Step 1
If ActiveCell.Value = "" Then
Selection.Delete Shift:=xlUp
ElseIf ActiveCell.Value <> "" Then
ActiveCell.Offset(1, 0).Select
End If
Next count
End Sub