Complete remove blank line in Excel

I use the below VBA code to remove the blank lines in Excel. However, it still always detects over six thousands of lines. Any idea ? How to completely remove those records ?  Tks

LastRow = wkRecap.UsedRange.Rows.Count
LastCol = wkRecap.UsedRange.Columns.Count
Range(Cells(2, 1).Address(RowAbsolute:=False, ColumnAbsolute:=False) & ":" & Cells(LastRow, LastCol).Address(RowAbsolute:=False, ColumnAbsolute:=False)).Delete
AXISHKAsked:
Who is Participating?

Improve company productivity with a Business Account.Sign Up

x
 
Wayne Taylor (webtubbs)Connect With a Mentor Commented:
Try this....

Range(Cells(2, 1), Cells(Rows.Count, 1)).EntireRow.Delete
0
 
AXISHKAuthor Commented:
Tks
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.