473,405 Members | 2,160 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,405 software developers and data experts.

Pull data from one Array based on data in first Array


Hi,

I have a string Array called Groups and this has x number of groups.
Each row of the Array is divided up by ';' and has the name of the
group in the second position (i.e. after the first ';') and then x
number of values all divided by ';'. All these subsequent values are
the IDs of the contacts of the group

I then have a second string Array called Contacts and this has x number
of contacts.
Each row of the Contacts Array is divided by ';' and has the ID of the
contact first and the mobile number of the contact in the third
position (i.e. after the second ';')

I want to put the Group names into a drop down and dependent on the
group name picked...pull the mobile numbers of the Contacts of that
Group into a string.

I can get the Group names into the drop down but am unsure how to pull
the information from the second Array based on the Group name selected.

I know i have probably explained this badly but if anyone understands
and could give me some pointers, it would be much appreciated.

Thanks....

Nov 21 '05 #1
1 1866
kieran wrote:
Hi,

I have a string Array called Groups and this has x number of groups.
Each row of the Array is divided up by ';' and has the name of the
group in the second position (i.e. after the first ';') and then x
number of values all divided by ';'. All these subsequent values are
the IDs of the contacts of the group

I then have a second string Array called Contacts and this has x number
of contacts.
Each row of the Contacts Array is divided by ';' and has the ID of the
contact first and the mobile number of the contact in the third
position (i.e. after the second ';')

I want to put the Group names into a drop down and dependent on the
group name picked...pull the mobile numbers of the Contacts of that
Group into a string.

I can get the Group names into the drop down but am unsure how to pull
the information from the second Array based on the Group name selected.

I know i have probably explained this badly but if anyone understands
and could give me some pointers, it would be much appreciated.

Thanks....


I would think of breaking up your array (at least the second one) and
put it in a datatable. This way you can filter the datatable in a
dataview based on the selected in combobox1. Then apply the filtered
dataview to the datasource of the second combobox.
Chris
Nov 21 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

35
by: Troll | last post by:
Hi, I need to write a script which reads some data and reports the findings. Just to give you an idea the structure is similar to the following. Data input example: HEADING 1 **********...
6
by: Bimo Remus | last post by:
Hi, I am currently taking a C++ class and am having problems with a homework assignment. My problem is that I need to pull the first and last words out of of a character string array which is in...
4
by: Michael Kirchner | last post by:
Hi everybody The output of my multiple dimension array is quite confusing. Im declaring an array, store some values in it and then I save the array in a session variable. On an other page I...
2
by: Nick | last post by:
What I want to do is have 2 pull down lists, for example a state pull down list and a city pull down list. What I would like to have done is when you select a state from the state pull down list...
6
by: James | last post by:
I am using vb.net and need to keep in memory a large data structure, so I am looking for the best option. And after several test I am pretty confused. So I will be grateful if anyone can help me. ...
29
by: yourmycaffiene | last post by:
Okay, this if my first post so go easy on me plus I've only been using C for a couple of weeks. I'm working on a program currently that requires me to read data from a .dat file into a 2d array and...
8
by: Mark | last post by:
Hello. I am attempting to write binary data from a file to an OLE Object field, and then write the file back out from the database. I am reading and writing the files in binary mode, and using...
5
by: Smokey Grindle | last post by:
Ok I must admit I stink at regular expressions... been trying to learn them for a while now and its not sticking how I wish it would... but I am trying to take a very long string (about 30KB) and...
9
ADezii
by: ADezii | last post by:
One question which pops up frequently here at TheScripts is: 'How do I retrieve data from a Recordset once I've created it?' One very efficient, and not that often used approach, is the GetRows()...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.