Here is one way (demo'd from the immediate window)
v = Evaluate("{11,12,13,14;21,22,23,24;31,32,33,34;41,42,43,44}")
? v(1,1)
11
thisworkbook.Names.Add Name:="ABC", Refersto:=v
v1 = Evaluate(thisworkbook.Names("ABC").Value)
? v1(2,3)
23
--
Regards,
Tom Ogilvy
"(E-Mail Removed)" wrote:
> I am currently adapting some old VBA code and want store all my
> configuration settings as Names to eliminate having a separate
> worksheet for that. I have loaded strings and arrays into names and
> have been successful in pulling the strings back out into my code but
> when pulling the array back can only access the first value in the
> array and cannot find a method to pull specific rows/columns (i.e.
> array(2,3)). I have searched online and in VBA books I have and cannot
> find anything on this and none of my ideas for making it work have
> succeeded so does anyone know if this is even possible?
>
>
> Dustin Russell
>
>
|