View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
koalabeer koalabeer is offline
external usenet poster
 
Posts: 1
Default filling array with non-contiguous range


Hi everybody,

I have just started using VBA with excel and ran into the followin
problem:

If I want to fill an array with an excel column I can do:

array_in = Range("A1:A7").Value

this works fine. But now I want to create a two dimensional array wher
I want to fill each dimension with a different excel column (the tw
columns have an empty column in between them). So I tried:

array_in = Range("A1:A7,C1:C7").Value

however this didn't worked out. Of course I can do:

array_in = Range("A1:C7").Value, but then I create a three dimensiona
array with the second dimension empty. This will work but seems rathe
silly to me;-) Maybe I am overlooking something obvious but as a
excuse I am only a starter;-)

Can somebody help me?

Thanks,

Stev

--
koalabee
-----------------------------------------------------------------------
koalabeer's Profile: http://www.excelforum.com/member.php...fo&userid=2989
View this thread: http://www.excelforum.com/showthread.php?threadid=49605