View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
kkknie[_20_] kkknie[_20_] is offline
external usenet poster
 
Posts: 1
Default Using a Macro to find a value in a range and activate it

I may be misunderstanding, but how about:


Code
-------------------
Sub test()

Dim r As Range
Dim strFind As String

strFind = Range("B13").Value

For Each r In Range("E13:F22")
If r.Value = strFind Then
r.Select
Exit For
End If
Next

End Su
-------------------



--
Message posted from http://www.ExcelForum.com