ARRAY IN

B

Bernie Deitrick

Marina,

RR = Array("John", "mary")
A = "Fred"
If IsError(Application.Match(A, RR, False)) Then
MsgBox "No"
Exit Sub
Else
MsgBox "Yes"
'Other Code
End If

HTH,
Bernie
MS Excel MVP
 
M

Marina Limeira

How I test if the name is in a array?

I try


RR= array("John", "mary")

IF A in RR then
msgbox("yes")
end if

but the IN in if not execute..

thanks for help me

Marina
 
Top