I have a sheet with out 4000+ products on it (item numbers & descriptions) - I would like to create a search option for the guys in the field (much like in MSWord) where you enter keyword(s) and it will highlight every instance of the word. (highlight word, cell, entire row I dont care.)
I realize you can use the generic "Find" however, many of the guys do not do much other than enter information & print what they need from Excel. The easier I can make it for them, the happier they will be.
this is what i have (please dont laugh) I could be WAY off base
Dim sUserString As String
sUserString = InputBox("Enter Keyword", _
"Keyword")
Do
Selection.Find.ClearFormatting
Selection.Find.Replacement.ClearFormatting
Selection.Find.Replacement.Highlight = True
With Selection.Find
.Text = sUserString
.Replacement.Text = sUserString
.Forward = True
.Wrap = wdFindstop
.Format = True
.MatchCase = False
.MatchWholeWord = False
.MatchWildcards = False
.MatchSoundsLike = False
.MatchAllWordForms = False
End With
Selection.Find.Execute
If Not Selection.Find.Found Then Exit Do
MsgBox "egads!!"
Loop
I realize you can use the generic "Find" however, many of the guys do not do much other than enter information & print what they need from Excel. The easier I can make it for them, the happier they will be.
this is what i have (please dont laugh) I could be WAY off base
Dim sUserString As String
sUserString = InputBox("Enter Keyword", _
"Keyword")
Do
Selection.Find.ClearFormatting
Selection.Find.Replacement.ClearFormatting
Selection.Find.Replacement.Highlight = True
With Selection.Find
.Text = sUserString
.Replacement.Text = sUserString
.Forward = True
.Wrap = wdFindstop
.Format = True
.MatchCase = False
.MatchWholeWord = False
.MatchWildcards = False
.MatchSoundsLike = False
.MatchAllWordForms = False
End With
Selection.Find.Execute
If Not Selection.Find.Found Then Exit Do
MsgBox "egads!!"
Loop