Removing Blank rows
Removing Blank rows
Last edited by macrolearnerkk; 09-07-2015 at 02:55 PM.
Code:
http://www.excelforum.com/excel-prog...el-2010-a.html
PHP Code:
Sub DelRows()
Application.ScreenUpdating = False
Dim ws As Worksheet
Dim LastRow As Long
Dim response As String
response = InputBox("Please enter search string.")
For Each ws In Sheets
LastRow = ws.Cells.Find("*", SearchOrder:=xlByRows, SearchDirection:=xlPrevious).Row
ws.Range("A1:E" & LastRow).AutoFilter Field:=1, Criteria1:=response
ws.Range("A2:E" & LastRow).SpecialCells(xlCellTypeVisible).EntireRow.Delete
ws.AutoFilterMode = False
Next ws
Application.ScreenUpdating = True
End Sub
Last edited by macrolearnerkk; 09-07-2015 at 02:57 PM.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks