Perhaps something along the lines of:
Colin Legg provides a much better overview (and indeed) code of how to go about deleting rows in Excel - see: http://www.xtremevbtalk.com/showthread.php?t=300757![]()
Sub Example() With Sheets("855_FN005_DETAILED_ERROR").UsedRange.Columns(1) .AutoFilter Field:=1, Criteria1:="<>*dos*" On Error Resume Next .Offset(1).SpecialCells(xlCellTypeVisible).EntireRow.Delete On Error GoTo 0 .AutoFilter .Sort Key1:=.Cells(1), Header:=xlNo End With End Sub
Bookmarks