Martin Lee

My Personal Site

Arrays

Arrays in VB.NET

Unlike other vesions of visual basic an array index always starts at zero. (Worth noting on upgrading)

Object Orientented Programing (OOP) Arrays come under System.Array. You can declare an array using Dim, ReDim, Private, Protected, Public and  Static keywords.

'Dimension an array with 6 elements of type String
Dim MyArray(5) as String
Dim MyString,  as String
MyArray(0) = "Position 1"
MyArray(1) = "Position 2"
MyArray(2) = "Position 3"
MyArray(3) = "Position 4"
MyArray(4) = "Position 5"
MyArray(5) = "Position 6"

What else can you do with array

Links Worth kooking at: