Thread: Match
View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Per Jessen Per Jessen is offline
external usenet poster
 
Posts: 1,533
Default Match

Hi

Maybe this is what you need:

Sub MyMatch()
Set TargetRange = Range("A1:A4")
Set MatchCell = Range("B1")
MatchValue = WorksheetFunction.Match(MatchCell, TargetRange, 0)
MsgBox ("Match is : " & MatchValue)
End Sub

Regards,
Per

"fi.or.jp.de" skrev i meddelelsen
...
Hi All,

i have value B_12-23

it should match with
B_12-23
B_12 23
B 12 23
B1223

I need vba solution.

Thanks in advance.