<Previous lesson | Table of Content | Content of this Chapter | Next lesson>

Getting Value from Array

Syntax: VarName = ArrayName(index)
Example:


Dim I As Integer
Dim MatrixA(3 To 10) As Double
Dim myVal as Double
For I = 1 To 10
MatrixA(I) = I * Rnd + 1
Me.Print Format(MatrixA(I), “0.00”)
Next I

Note: refer to VB help file for explanation about Format.

<Previous lesson | Table of Content | Content of this Chapter | Next lesson>