Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Set ws = ThisWorkbook.Worksheets("T&E Report")
- MyLastRow1 = Range("C100000").End(xlUp).Row
- findarray = Array("J")
- ReDim filterarray(0 To 0)
- j = 0
- For k = 0 To UBound(findarray)
- For i = 2 To MyLastRow1
- If InStr(ws.Cells(i, 3).Value, findarray(k)) > 0 Then
- filterarray(j) = ws.Cells(i, 3).Value
- j = j + 1
- ReDim Preserve filterarray(0 To j)
- End If
- Next i
- Next k
- ws.Range("$C$1:$C$" & MyLastRow1).AutoFilter Field:=3, Criteria1:=Array(filterarray), Operator:=xlFilterValues
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement