sijpie
Well-known Member
- Joined
- Nov 1, 2008
- Messages
- 4,269
- Office Version
- 365
- Platform
- Windows
- MacOS
If I declare a 2 dimensional array I can load a range into it fairly simple:
But what if I want to add say A1:A10, C1:C10, F1:F10 and G1:G10 into the array. I have tried:
but vba doesn't seem to like that.
Any smart way to do this (I try to avoid looping)?
Can you address just one column of the array? (or one row for that matter)
Code:
dim MyArr(1 to 10,1 to 4)
MyArr = Range("A1:D10")
But what if I want to add say A1:A10, C1:C10, F1:F10 and G1:G10 into the array. I have tried:
Code:
MyArr(1) = Range("A1:A10")
Any smart way to do this (I try to avoid looping)?
Can you address just one column of the array? (or one row for that matter)