Jim Maccauley
January 14th, 2000, 12:58 PM
I've defined a type with 4 integers and 3 boolean variables.
When i declare one dimensional array of 4864 cells containing this type, VB smiles and chugs along nicely.
If I try to declare a 2 dimensional array (1 to 76,1 to 64) of this type, VB chokes and tells me that static types can't exceed 64k.
Both arrays have the same number of cells, but the second would be easier for me to use.
The question is this, how much overhead is required for multidimensional arrays?
Jim's silly ideas :I would have thought that the compiler would represent multidimensioned arrays as an array of arrays each cell containing a pointer to a 1 dimensional array holding the actual data.
(this is probably the type of structure I'm going to cobble together, either that or the flat array with extra processing at run time)
Would I reduce the overhead by creating my own Array of arrays?
They said 'Jump!'.
I said 'How high?'
They said 'We don't know, just jump.'
When i declare one dimensional array of 4864 cells containing this type, VB smiles and chugs along nicely.
If I try to declare a 2 dimensional array (1 to 76,1 to 64) of this type, VB chokes and tells me that static types can't exceed 64k.
Both arrays have the same number of cells, but the second would be easier for me to use.
The question is this, how much overhead is required for multidimensional arrays?
Jim's silly ideas :I would have thought that the compiler would represent multidimensioned arrays as an array of arrays each cell containing a pointer to a 1 dimensional array holding the actual data.
(this is probably the type of structure I'm going to cobble together, either that or the flat array with extra processing at run time)
Would I reduce the overhead by creating my own Array of arrays?
They said 'Jump!'.
I said 'How high?'
They said 'We don't know, just jump.'