Following subroutine deletes all blank lines from current work sheet from the bottom with the range defined A1:Z50.
Dim range As range, rows As Integer, i As Integer
Set range = ActiveSheet.range("A1:Z50")
rows = range.rows.Count
For i = rows To 1 Step (-1)
If WorksheetFunction.CountA(range.rows(i)) = 0 Then range.rows(i).Delete