Cycle Through an Array
Cycle through an array with a For..Next loop.
Dim i As Long
For i = Lbound (MyArray) To Ubound (MyArray)
'do something with MyArray(i)
Next i
'if you know the upper/lower limits of the array, just use them
Dim MyArray(100) 'default lower limit is zero in VB
For i = 0 To 100
'do something to MyArray(i)
Next i
Special Instructions
This content is reprinted for archival purposes from Gary Beene's Information Center, with permission from Mr. Beene himself.
Loading Comments ...
Comments
No comments have been added for this post.
You must be logged in to make a comment.