Thread: VBA ".Find"
View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Rowan Drummond[_3_] Rowan Drummond[_3_] is offline
external usenet poster
 
Posts: 414
Default VBA ".Find"

Maybe this will help:

Sub findit() 'finds the text "findthis" in column A
Dim fndRange As Range
With Columns(1)
Set fndRange = .Find(what:="findthis", LookIn:=xlValues)
End With
If fndRange Is Nothing Then
MsgBox "Not found"
Else
fndRange.Interior.ColorIndex = 35
End If
End Sub

Regards
Rowan

SidBord wrote:
I'm having trouble understanding the VBA ".Find" method. VBA Help hasn't
been much help. I'd like to see a better writeup with examples. Any
suggestions about where to look?