Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have an array that I use for many different things. Thus the size of the
array may vary depending on the different tasks. I declare the array in a sub and then poulate the array with contents depending on an index number that has been sent to the sub. Code: Private arrayMaker(index As Integer) Dim array(1 to 100) As Variant if index = 0 then array(0) = "Interest rate" array(1)="Delta" rayy(2)=...etc. end if if index =1....etc.. end if As you can see there is no point in setting one size for every array. Instead I want to ReDim the array depending on the number of inputs I use. How do you do this? Thanks! |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
VBA syntax help: ReDim Preserve an array | Excel Discussion (Misc queries) | |||
ReDim Object array as parameter of Variant array | Excel Programming | |||
Dim / Redim of an Array | Excel Programming | |||
Redim 2D Array Subscript Out Of Range Error | Excel Programming | |||
ReDim an Array | Excel Programming |