View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Kobayashi[_30_] Kobayashi[_30_] is offline
external usenet poster
 
Posts: 1
Default Lookup 'Like' values???

Tony,

Many thanks for your help! However, I wish to define and use ranges.
also wish to use this funciton in code, so:

Can I put a range in the below formula to replace the "XPBA" part? O
will I have to use some kind of loop through each of the lookup cells?

=MATCH("XPBA",A20:A23,-1)

Currently I have:

With myRange
For i = 4 To .Rows.Count
If ISLIKE(.Cells(i, 4) & "*", rngB(1, 1)) = True Then
MsgBox "true"
Else: MsgBox "false" '.Cells(i, 4).Select
End If
Next i
End With

This seems to kind of work except that I have to add the (1,1) to th
range which kind of defeats the purpose. Should I scap this altogethe
(if I'm going in the wrong direction?) of should I replace the ISLIK
function with the Match function you have kindly provided?

Regards,

Adria

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