consider the following snippet:
Dim myArray() As Long
ReDim myArray(1 to 2, -3 to 3)
myArray(1,-1) = 5
1
2
3
Dim myArray() As Long
ReDim myArray(1 to 2, -3 to 3)
myArray(1,-1) = 5
To the VBA programmer, no methods have been invoked. But behind the scenes the VB runtime has been busy. The ReDim statement invokes all of the following:
Call SafeArrayAllocDescriptor : Create the SAFEARRAY header structure
Set the lLbound and cElements properties on of each the two SAFEARRAYBOUND structures in the new SAFEARRAY’s rgsabound array.