Find and delete that complete row

  • On a larger range, this is probably considerably faster.

    Code
    Sub Replace_And_Delete()
        With ActiveSheet.UsedRange
            .Replace What:=12, Replacement:="", Lookat:=xlWhole
            .SpecialCells(4).EntireRow.Delete Shift:=xlUp
        End With
    End Sub
  • And if you have rows where there would be a 12 on more than one occasion, you might have to use a looping code.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!