Hello, first time posting...I borrowed a bit of code to create a search box in cell B1. This allows me to search in the Range for a keyword, and it returns matching rows.
I would like to know how to expand this, in order to search for two or three keywords.
Thank you!
I would like to know how to expand this, in order to search for two or three keywords.
Thank you!
Code:
Sub MyAdvancedSearch()
Application.ScreenUpdating = False
Dim r As Range, v As String, s As String
With Sheets("August")
.Range("c2").CurrentRegion.EntireRow.Hidden = False
s = LCase(.Range("b1").Value)
For Each r In .Range("c4", .Range("c" & .Rows.Count).End(xlUp))
v = ""
v = v & r.Value
v = v & r.Offset(0, 1).Value
v = v & r.Offset(0, 2).Value
v = v & r.Offset(0, 3).Value
v = v & r.Offset(0, 4).Value
v = LCase(v)
If Not v Like "*" & s & "*" Then
r.EntireRow.Hidden = True
End If
Next r
End With
Application.ScreenUpdating = True
End Sub