ubound 2 dimensional array vba code example
Example: vba ubound array 2-dimensional
Dim arr(1 To 4, 1 To 3) As Variant
Debug.Print UBound(arr) ' returns 2
Debug.Print UBound(arr, 1) ' returns 4
Debug.Print UBound(arr, 2) ' returns 3
Dim arr(1 To 4, 1 To 3) As Variant
Debug.Print UBound(arr) ' returns 2
Debug.Print UBound(arr, 1) ' returns 4
Debug.Print UBound(arr, 2) ' returns 3