0

This is my first exposure to arrays. I need to create a 1-dimensional string-based array with five elements. I need to assign 5 different names to the array. Use a for loop to iterate through each of the array elements, displaying the names in a message box.

I would truly appreciate it if someone could help me out on this...

Option Compare Database

Private Sub cmdPopulate_Click()
Dim myStringArray(1 To 5) As String
Dim x(1)
Dim y(2)
Dim x(3)
Dim x(4)
Dim x(5)

For x = 1 To 5

myStringArray(x) = "The value of myStringArray is " & x

Next x

For x = 1 To 5

MsgBox "AddItem myStringArray (x)"

Next x

End Sub
1
Contributor
1
Reply
2
Views
9 Years
Discussion Span
Last Post by clueless101
This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.