This is my code. When I run it and no row haw the word Period it gives me the error Run-Time Error 1004 no cells were found. Any help would be appreciated.
Rows("4:4").Select
Selection.Delete Shift:=xlUp
Dim A1 As Range
With Range("A1", Range("A" & Rows.Count).End(xlUp))
.Replace "Period ", True, xlWhole, , False, , False, False
For Each Al In .SpecialCells(xlConstants, xlLogical).Areas
Al.Resize(3).EntireRow.Delete
Next Al
End With
Rows("4:4").Select
Selection.Delete Shift:=xlUp
Dim A1 As Range
With Range("A1", Range("A" & Rows.Count).End(xlUp))
.Replace "Period ", True, xlWhole, , False, , False, False
For Each Al In .SpecialCells(xlConstants, xlLogical).Areas
Al.Resize(3).EntireRow.Delete
Next Al
End With