Hi,
I have the code below which works but has an issue in that it always deletes Row 9 whether it meets the criteria or not - any help much appreciated.
Thanks
I have the code below which works but has an issue in that it always deletes Row 9 whether it meets the criteria or not - any help much appreciated.
Thanks
VBA Code:
Dim lr&
Application.ScreenUpdating = False
ActiveSheet.AutoFilterMode = False
lr = Cells(Rows.Count, "CZ").End(xlUp).Row
With Range("CZ9:CZ" & lr)
.AutoFilter field:=1, Criteria1:="<" & Range("CM3").Value
.SpecialCells(xlCellTypeVisible).EntireRow.delete
End With
ActiveSheet.AutoFilterMode = False
Application.ScreenUpdating = True