View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Bob Phillips Bob Phillips is offline
external usenet poster
 
Posts: 10,593
Default Find text string within a named range

Set RngToSearch = ActiveWorkbook.Range("tipos_dcto")


--
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)

"AshMorK" wrote in message
...
Hi all,

I'm trying to find a text string using a named range as the searching area
but it doesn't work:

Sub names()
Dim RngToSearch As Name
Dim RngFound As Range
Set RngToSearch = ActiveWorkbook.names("tipos_dcto")

c = ActiveCell.Value

Set RngFound = RngToSearch.Find(c)

If RngFound Is Nothing Then
MsgBox "xxx"
Else

End If

End Sub

Any Ideas??

Thanks in advance.