Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have a routine that uses dynamic arrays. At certain
points in the program I need to clear out the arrays so that they have NO elements (no UBound in other words), just like in their virgin state. For instance: Option Base 1 'in declarations Dim MyArray() As String 'a dynamic array with no UBound ReDim MyArray(3) 'dimension for 3 elements MyArray(1) = "Monday" MyArray(2) = "Tuesday" MyArray(3) = "Wednesday" 'now I want to return the array to the '"no UBound" state like it started in. ReDim MyArray 'compile error / syntax error ReDim MyArray() 'compile error / syntax error ReDim MyArray(1) 'no error, but UBound is now 1 Is there any way to do this? Art |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Complex conditional summing - array COUNT works, array SUM gives#VALUE | Excel Worksheet Functions | |||
Prevent cell/array references from changing when altering/moving thecell/array | Excel Discussion (Misc queries) | |||
VBA syntax help: ReDim Preserve an array | Excel Discussion (Misc queries) | |||
meaning of : IF(Switch; Average(array A, array B); array A) | Excel Worksheet Functions | |||
Redim MyArray | Excel Programming |