Q
qpg
I have some subroutines that take apart a selected matrix into x, y,
and value sets (each “record” representing an intersection on the
matrix). I am now trying to figure out the right data structure to put
it into so that I can pass it to another sub for more processing and
eventually to place back into excel as 3 columns
Is this a job for a 3 dimensional array? Or for a one dimensional
array of arrays each internal array holding one “record”? Or is there
a better way to do this? The data would only be accessed as records
I’m looking for examples how to both assign and access the 3
dimensional array. I’m only an occasional programmer and seem to be
having some problems with the 3D idea and not sure how to implement
others.
This seems to assign a 3D array:
outdata(i, j, x) = Array(Range(left)(i + 1, 1), Range(top)(1, j +
1), d.Value)
but then when I try to access it I get a type mismatch error
Debug.Print outdata(1, 1, 1)
Any help or pointing in the right direction is appreciated.
Thanks
and value sets (each “record” representing an intersection on the
matrix). I am now trying to figure out the right data structure to put
it into so that I can pass it to another sub for more processing and
eventually to place back into excel as 3 columns
Is this a job for a 3 dimensional array? Or for a one dimensional
array of arrays each internal array holding one “record”? Or is there
a better way to do this? The data would only be accessed as records
I’m looking for examples how to both assign and access the 3
dimensional array. I’m only an occasional programmer and seem to be
having some problems with the 3D idea and not sure how to implement
others.
This seems to assign a 3D array:
outdata(i, j, x) = Array(Range(left)(i + 1, 1), Range(top)(1, j +
1), d.Value)
but then when I try to access it I get a type mismatch error
Debug.Print outdata(1, 1, 1)
Any help or pointing in the right direction is appreciated.
Thanks