dim c as long ,a(2,3,4,5) as long 
c=UBound(A,1)
c=UBound(A,2)
c=UBound(A,3)
c=UBound(A,4)
c=UBound(A,5)
...........
...........
...........直到出错为止,就知道了