Hello,
I'm fairly new to these Excel Macros and need some help.
I have this code that does work where it looks for the word "Fail" in Column B and grabs the text in Column C.
How would I update the code to now include looking for "Fail" and "Exception".
Thanks in advance for any help!
With Worksheets("Test")
yrow = .Range("A" & .Rows.Count).End(xlUp).Row
.Range("A1:D" & yrow).AutoFilter field:=2, Criteria1:="Fail"
lastRow = Worksheets("Comments").Range("B" & Rows.Count).End(xlUp).Row
On Error Resume Next
.Range("A3:A" & yrow).SpecialCells(xlCellTypeVisible).Copy Worksheets("Comments").Range("A" & lastRow + 1)
.Range("C3:C" & yrow).SpecialCells(xlCellTypeVisible).Copy Worksheets("Comments").Range("B" & lastRow + 1)
.Rows(1).AutoFilter
End With
Bookmarks