Solved

Searching the 2-D array

Posted on 2007-03-27
1
152 Views
Last Modified: 2013-11-26
Hi,

I have a 2-D array. First dimension has name of control and the second dimension has the associated value. Let us say first dimension has name of all text boxes and the second has its value. Now how do I seach value for a particular text box, for example, I want to know the value of say txtName?

I do not want to loop through the array as my array will be large and this approach will be time consuimg.

Regards,
MI
0
Comment
Question by:vj_mi
1 Comment
 
LVL 25

Accepted Solution

by:
dstanley9 earned 500 total points
ID: 18802900
The built-in search methods do not support multi-dimensional arrays.

If possible, I would not use an array, but use a Hashtable in .NET 1.1 or a Dictionary<string,???> in .NET 2.0 where ??? is the type of value you want to store.  There are much easier to search and manupulate than a 2-D array.

0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Flash (http://en.wikipedia.org/wiki/Adobe_Flash) has evolved over the years to where it has become a masterful tool for displaying content screen.  It has excellent layout placement, UI precision as well as rendering capabilities. This, along with t…
This article shows how to deploy dynamic backgrounds to computers depending on the aspect ratio of display
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…

840 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question