Simon Lloyd
04-23-2009, 12:00 AM
Hi all, currently i am creating collections to fill comboboxes for viewing purposes, however, i really would rather show them on a message box but it doesn't accept a collection anyone know how to do it?
The variables have been declared as collections.
For Each Cel In rng
Select Case LCase(Cel.Value)
Case "Ms": Msa.Add Cells(1, Cel.Column).Value, CStr(Cells(1, Cel.Column).Value)
Case "Ks": Ksa.Add Cells(1, Cel.Column).Value, CStr(Cells(1, Cel.Column).Value)
Case "Ds": Dsa.Add Cells(1, Cel.Column).Value, CStr(Cells(1, Cel.Column).Value)
Case "Os": Osa.Add Cells(1, Cel.Column).Value, CStr(Cells(1, Cel.Column).Value)
Case "Ts": Tsa.Add Cells(1, Cel.Column).Value, CStr(Cells(1, Cel.Column).Value)
End Select
Next Cel
The variables have been declared as collections.
For Each Cel In rng
Select Case LCase(Cel.Value)
Case "Ms": Msa.Add Cells(1, Cel.Column).Value, CStr(Cells(1, Cel.Column).Value)
Case "Ks": Ksa.Add Cells(1, Cel.Column).Value, CStr(Cells(1, Cel.Column).Value)
Case "Ds": Dsa.Add Cells(1, Cel.Column).Value, CStr(Cells(1, Cel.Column).Value)
Case "Os": Osa.Add Cells(1, Cel.Column).Value, CStr(Cells(1, Cel.Column).Value)
Case "Ts": Tsa.Add Cells(1, Cel.Column).Value, CStr(Cells(1, Cel.Column).Value)
End Select
Next Cel