PC Review


Reply
Thread Tools Rate Thread

Addressing a named Array

 
 
William Foster
Guest
Posts: n/a
 
      13th Feb 2007
Good morning all,

Does anyone know how to address a named Array, for instance:

Array_States(1) = "New South Wales"

Array_Name = "Array_States"
Value = Array_Name(1)

Therefore, Value = "New South Wales"

I know that this looks very messy, but hopefully you can understand what
I mean.

Basically I have about 20 or 30 arrays that I want to be able to called
via one procedure, and just change the array that each name that I am
referencing.

Any assistance you may be able to provide would be appreciated.

Yours sincerely,

William Foster

*** Sent via Developersdex http://www.developersdex.com ***
 
Reply With Quote
 
 
 
 
Tom Shelton
Guest
Posts: n/a
 
      13th Feb 2007
On Feb 12, 6:30 pm, William Foster <nos...@devdex.com> wrote:
> Good morning all,
>
> Does anyone know how to address a named Array, for instance:
>
> Array_States(1) = "New South Wales"
>
> Array_Name = "Array_States"
> Value = Array_Name(1)
>
> Therefore, Value = "New South Wales"
>
> I know that this looks very messy, but hopefully you can understand what
> I mean.
>
> Basically I have about 20 or 30 arrays that I want to be able to called
> via one procedure, and just change the array that each name that I am
> referencing.
>
> Any assistance you may be able to provide would be appreciated.
>
> Yours sincerely,
>
> William Foster
>
> *** Sent via Developersdexhttp://www.developersdex.com***


off the top of my head, I would make use a dictionary or a hashtable
of arrays - depending if the arrays were the same type...

--
Tom Shelton

 
Reply With Quote
 
Cor Ligthert [MVP]
Guest
Posts: n/a
 
      13th Feb 2007
William,

Be aware that this is a 24 hours newsgroup not only for New South Wales.

It is hard to understand for me what you want, but the most goes in my idea
the answer on your question to Enum.

http://msdn2.microsoft.com/en-us/lib...stem.enum.aspx


Cor

"William Foster" <(E-Mail Removed)> schreef in bericht
news:(E-Mail Removed)...
> Good morning all,
>
> Does anyone know how to address a named Array, for instance:
>
> Array_States(1) = "New South Wales"
>
> Array_Name = "Array_States"
> Value = Array_Name(1)
>
> Therefore, Value = "New South Wales"
>
> I know that this looks very messy, but hopefully you can understand what
> I mean.
>
> Basically I have about 20 or 30 arrays that I want to be able to called
> via one procedure, and just change the array that each name that I am
> referencing.
>
> Any assistance you may be able to provide would be appreciated.
>
> Yours sincerely,
>
> William Foster
>
> *** Sent via Developersdex http://www.developersdex.com ***



 
Reply With Quote
 
Spam Catcher
Guest
Posts: n/a
 
      13th Feb 2007
William Foster <(E-Mail Removed)> wrote in news:ud1M75wTHHA.5068
@TK2MSFTNGP03.phx.gbl:

> Basically I have about 20 or 30 arrays that I want to be able to called
> via one procedure, and just change the array that each name that I am
> referencing.


How about using dictionarys + lists/arrays instead

For example:

State("New South Wales")(0) = "Some Province/State"
 
Reply With Quote
 
William Foster
Guest
Posts: n/a
 
      13th Feb 2007
Thanks for the tips everybody, I am interested in the dictionary option,
I haven't used that previously.

I will give it a try tomorrow and call out for more help if I need it (I
am trying to be positive, but I am pretty sure I will need it).

Yours sincerely,

William Foster

*** Sent via Developersdex http://www.developersdex.com ***
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
how do i maintain named range addressing after deleting row? =?Utf-8?B?ZXJw?= Microsoft Excel Programming 0 1st Dec 2005 01:52 AM
Converting a 4D array to a 1D array and addressing it elziko Microsoft VB .NET 4 27th Jun 2005 09:11 AM
Converting a 4D array to a 1D array and addressing it elziko Microsoft Dot NET Framework 4 27th Jun 2005 09:11 AM
Converting a 4D array to a 1D array and addressing it elziko Microsoft Dot NET 4 27th Jun 2005 09:11 AM
Addressing a group of Named Ranges Mike Fogleman Microsoft Excel Programming 5 18th May 2004 02:43 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 04:26 AM.