Private Sub Form_Load()
Dim arr() As String
Dim i As Integer
Dim j As Integer
Dim k As Integer
Dim v As Variant
' Initialize the array.
ReDim arr(1 To 2, 10 To 12, 69 To 71)
For i = LBound(arr, 1) To UBound(arr, 1)
For j = LBound(arr, 2) To UBound(arr, 2)
For k = LBound(arr, 3) To UBound(arr, 3)
arr(i, j, k) = i & ", " & j & ", " & k
Next k
Next j
Next i
' Iterate over the items in the array using For Each.
For Each v In arr
Debug.Print v
Next v
End Sub
|