Pirahnaplant
Well-known member
- Joined
- Mar 29, 2009
- Messages
- 75
- Programming Experience
- 3-5
Basically I want to find the first occurrence of one array in another. I have tried using the Array.IndexOf Function, but it always returns -1.
Example:
Even though array2 does exist in array1, the message box always shows -1
Example:
VB.NET:
Dim array1 As Byte() = {1, 2, 3, 4, 5}
Dim array2 As Byte() = {2, 3}
MsgBox(Array.IndexOf(array1, array2))