Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Excel : Array Naming 1

Status
Not open for further replies.

gmeunier

Programmer
Nov 6, 2000
9
FR
Hi there,

I have an undefined number of currencies for which I am calculating an exchange rate.

I am willing to put those rates in an array for further calculations.

What I would like to end up with is something like :
dXRate("EUR")=1
dXRate("USD")=1.2
So that at then end I could call back the Xrate with the following synthax : dXRate(stCur)

It seems that one can only give an index to an array :
dXRate(0) or dXRate(1)

Has anyone an idea? Use of Excel only...

Many thanks,

Gerald
 
You may use either a VBA.Collection or a Scripting.Dictionary object.

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 

Many thanks PHV,

I never heard before of VBA.collection.
Found some material on the web, and works great for my problema.

Thanks again,

Gerald
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top