Does anyoneknow a simple vba code to delete blanks rows?
Thank you
Does anyoneknow a simple vba code to delete blanks rows?
Thank you
![]()
Sub delblank() Range("A:A").SpecialCells(xlCellTypeBlanks).EntireRow.Delete End Sub
If solved remember to mark Thread as solved
Hi. patel45,
running that code will have 2 carvats: it considers the full length of Column A and all empty cells below the used range if so avoids the run time error when no empty cells are found in the area.
Ciao,![]()
Sub delblank() On Error Resume Next ActiveSheet.UsedRange.Range("A:A").SpecialCells(xlCellTypeBlanks).EntireRow.Delete If Err Then MsgBox "No blank cells" End If End Sub
Holger
Use Code-Tags for showing your code: [code] Your Code here [/code]
Please mark your question Solved if there has been offered a solution that works fine for you
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks