Given an array, I would like to have a function which determines if a string of characters exists in an array. The string of characters must be EXACTLY the same in input of the function, and the array content.
Function IsInArray(ThsStrng As String, arr() As String, bnd As Integer) As Boolean
For Z = 1 To bnd
If arr(Z) = ThsStrng Then
IsInArray = True
Else
IsInArray = False
End If
Next Z
End Function
At first, it seemed like the function ran correctly. After using this function a few times, I noticed that the False value (meaning that the input string does not equal to a value in the array), was not correct (there were input values that were exactly the same a value in the array).
Please help,
IsNumeric(Application.Match("string to look for",arrayVariable,0))? it will be true if an exact match exists and be false if not...