Here is the function I have so far:
This works correctly and deletes the text from all cells that do not contain "D.R." However, I also want to keep cells that contain the text "F.G." and "WIP".Sub ClearUnwantedCells() Dim c As Range Worksheets("Aurora").Activate Range("R2").Select For Each c In Range(Selection, Selection.End(xldown)) If Not (Len(WorksheetFunction.Substitute(UCase(c), "D.R.", "")) <> Len(c)) Then c.Clear Next c End Sub
I'm not sure how the syntax of the OR operator would work in this situation. Any help is appreciated. Thanks.
Bookmarks