There's no way to do this is
VB/VBA. It's just not a supported feature.
--
Rob Bovey, MCSE, MCSD, Excel MVP
Application Professionals
http://www.appspro.com/
* Please post all replies to this newsgroup *
* I delete all unsolicited e-mail responses *
"J Kruger" wrote in message
m...
Hi,
I have been looking everywhere on how to create dynamic variables in
excel.
I want the same result as what the eval() function in JavaScript gives.
ie.
a1 = new Array(10);
a1[0] = "hello";
alert(eval("a" + 1)[0]);
or
for(i = 0; i <=10; i++){
eval("a"+i) = i;}
Any help would be appreciated.