Home |
Search |
Today's Posts |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
redim is probably the best option here. If you know the size of the array at
runtime then use the redim statement to set the size. (redim preserve if you want to change the size of an existing populated array) Don't make an array the is huge to store a small amount of data. If you do you will not effectively be able to traverse the array looking for an item in the array. Also it is a huge waste of memory. -- HTH... Jim Thomlinson "Mark" wrote: Efficient Arrays: Setting size equal to count? If I have an array that, based on the data loaded to the program, could need to be rather small(10) or very large (10000), if there a way to selectively set the size. If I made the array dynamic, can I redim = count where count is a variable based on the number of rows in a column? Or is there no harm in dim an array as very large an only using a small part of it? Does the unused portion pose a large drain on resources? |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Efficient linking | Excel Discussion (Misc queries) | |||
What is more efficient | Excel Discussion (Misc queries) | |||
More efficient way? | Excel Programming | |||
Loop more efficient ? | Excel Programming | |||
Which is more efficient? | Excel Programming |