Accessing an Item in a Custom Collection
Sub AccessCollection()
Dim colNames As Collection
Set colNames = New Collection
colNames.Add "A", "A"
colNames.Add "D", "D"
colNames.Add "A2", "A2"
colNames.Add "B", "B"
colNames.Add "S", "S"
colNames.Add "S3", "S2"
Debug.Print colNames.Item(1)
End Sub
Related examples in the same category