VB.NET 2-dimensional array

How do you search within a 2-dimensional array using VB.NET? How can I know that a value already exists in the array?

Questions by Myra13

Showing Answers 1 - 2 of 2 Answers

Dim arr(1, 2) As String
       arr(0, 0) = "Sandip"
       arr(0, 1) = "India"
       arr(1, 0) = "Jon Doe"
       arr(1, 1) = "US"


  Was this answer useful?  Yes


  • Nov 12th, 2012

Use two for loops.
one for the columns and one for the rows.
exit for as soon as you find the value (preferably return true that you found the value)

  Was this answer useful?  Yes

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.


Related Answered Questions


Related Open Questions