array question

D

djc

I would love some yes/no's on these:

1) Dim varArray(10)

No option base statement. This array should have 10 total elements w/
subscripts 0 to 9. Yes/No?

2) Dim varArray(10)

No option base statement. This array should have 11 total elements w/
subscripts 0 to 10. Yes/No?

Thanks.
 
M

Michel Walsh

Hi,


No. In VBA and in Classic VB, the index, is the maximum value it can
take. In both case, varArray(10) is valid. The first case is equivalent to

Dim x( 0 to 10)

and the second case, to

Dim x(1 to 10)



Hoping it may help,
Vanderghast, Access MVP
 
D

djc

Thanks.

Michel Walsh said:
Hi,


No. In VBA and in Classic VB, the index, is the maximum value it can
take. In both case, varArray(10) is valid. The first case is equivalent to

Dim x( 0 to 10)

and the second case, to

Dim x(1 to 10)



Hoping it may help,
Vanderghast, Access MVP
 
Top