Message 1 of 10
Array of Arrays

Not applicable
01-08-2000
04:38 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Group,
I've created a one-dimensional array of two-dimensional arrays. I can see
the 2D arrays within the outer array, but I can't seem to dig out the second
dimension information. The 2D array looks like this:
DetailArray(0,0) = "Object name:"
DetailArray(0,1) = strObjName
DetailArray(1,0) = "Object ID:"
DetailArray(1,1) = intObjID
Then I assign this 2D array to the first element of a one-dimensional array
like this:
DetailsArray(0) = DetailArray
While watching the two arrays, I can see the information in the 2D array. I
can also see it in the one-dimensional array. It looks like this:
DetailsArray(0)(0)
Under that, I see the 2D array, but I cannot dig out the second dimension
for display. I assign the array to a list box with this:
lstDetails = DetailsArray(0)
but I only get the hard-coded strings, not the information contained in the
variables. I tried:
lstDetails = DetailsArray(0)(0)
because that is what the watch window shows, but that produces an out of
subscript range error. Does anyone know how to get the second dimension out
of the embedded array? Thanks.
--
Eugene N. Kilmer
Owner/Mag Drafting
I've created a one-dimensional array of two-dimensional arrays. I can see
the 2D arrays within the outer array, but I can't seem to dig out the second
dimension information. The 2D array looks like this:
DetailArray(0,0) = "Object name:"
DetailArray(0,1) = strObjName
DetailArray(1,0) = "Object ID:"
DetailArray(1,1) = intObjID
Then I assign this 2D array to the first element of a one-dimensional array
like this:
DetailsArray(0) = DetailArray
While watching the two arrays, I can see the information in the 2D array. I
can also see it in the one-dimensional array. It looks like this:
DetailsArray(0)(0)
Under that, I see the 2D array, but I cannot dig out the second dimension
for display. I assign the array to a list box with this:
lstDetails = DetailsArray(0)
but I only get the hard-coded strings, not the information contained in the
variables. I tried:
lstDetails = DetailsArray(0)(0)
because that is what the watch window shows, but that produces an out of
subscript range error. Does anyone know how to get the second dimension out
of the embedded array? Thanks.
--
Eugene N. Kilmer
Owner/Mag Drafting