Looping Through the Elements of a Custom Collection
Sub LoopThroughCollection() Dim colSports As New Collection Dim varSport As Variant
colSports.Add "Basketball"
colSports.Add "Skiing"
colSports.Add "Skating", Before:=1
colSports.Add "Hockey", After:=2
For Each varSport In colSports
Debug.Print varSport
Next varSport End Sub