View Single Post
  #8   Report Post  
Posted to microsoft.public.excel.programming
NickHK[_3_] NickHK[_3_] is offline
external usenet poster
 
Posts: 415
Default Append One Array to Another, and Consolidate

Could you start off with all the data in a single array ?
Then you do not have to combine them later.

Dim var As Variant

var = Union(Range("A1:B4"), Range("A5:B8"))

NickHK

"Stratuser" ...
The values are both strings (ticker symbols) and numbers associated with
the
tickers. They are pulled from columns on a worksheet.

"Morris" wrote:


Stratuser wrote:
Yes, but there is one other thing: My arrays are two-dimensional,
based on a
row and column structure, like a range. If I use ReDim Preserve to
increase
the big array to add the non-duplicate elements, I can only increase
the last
dimension of the array. Since I'm adding rows in effect, I guess I
would
need the array structure to be Array(column, row) instead of Array(row,
column). Right?


dunno :)

What kind of values have you got in the inner array? could you
consolidate them to a string using Join method - for the time of
comparation, and array redimensioning, and then do a loop throughout
the array to split them back? It's just a loose idea, as I'd prefere to
see the example itself