name ranges in array
I'm not sure what you're doing, but Union sounds like it might be what you're
looking for.
Dim K as long
dim rCtr as long
dim myRngs() as range
dim OneRng as range
k = 3
redim myRngs(1 to K)
with worksheets("Sheet9999")
set myrngs(1) = .range("A1")
set myrngs(2) = .range("w1:z1")
set myrngs(3) = .range("L9")
end with
set onerng = myrngs(lbound(myrngs))
for rctr = lbound(myrngs) + 1 to ubound(myrngs)
set onerng = union(onerng, myrngs(rctr))
next rctr
msgbox onerng.address
igorek wrote:
Hi Folks,
Can anyone help with the array feed please?
I have numerous name ranges in the file and i want to feed an array with it.
Let say i have K number of ranges. How do i feed Ranges() array with it?
Thanks
Igor
--
Dave Peterson
|