Private Sub UserForm_Initialize()
With ComboBox1
.ColumnCount = 2: Rem can be set at design time
.ColumnWidths = ";0": Rem optional, can be set at design time
.BoundColumn = 2: Rem design time
.TextColumn = 1: Rem design time
.List = Range("J3:K6").Value
End With
End Sub
Private Sub ComboBox1_Change()
With ComboBox1
If .ListIndex <> -1 Then
MsgBox .Text & " goes with " & .Value
End If
End With
End Sub
Private Sub UserForm_Initialize()
With who
.ColumnCount = 2: Rem can be set at design time
.ColumnWidths = ";0": Rem optional, can be set at design time
.BoundColumn = 2: Rem design time
.TextColumn = 1: Rem design time
.List = Range("J3:K6").Value
With kind
.ColumnCount = 2: Rem can be set at design time
.ColumnWidths = ";0": Rem optional, can be set at design time
.BoundColumn = 2: Rem design time
.TextColumn = 1: Rem design time
.List = Range("l3:M8").Value
End With
End Sub
Got it.... I needed to add a End With
Thanks for all your help!!
Private Sub UserForm_Initialize()
With who
.ColumnCount = 2: Rem can be set at design time
.ColumnWidths = ";0": Rem optional, can be set at design time
.BoundColumn = 2: Rem design time
.TextColumn = 1: Rem design time
.List = Range("J3:K6").Value
End With
Private Sub UserForm_Initialize()
With who
.ColumnCount = 2: Rem can be set at design time
.ColumnWidths = ";0": Rem optional, can be set at design time
.BoundColumn = 2: Rem design time
.TextColumn = 1: Rem design time
.List = Range("J3:K6").Value
End With
With kind
.ColumnCount = 2: Rem can be set at design time
.ColumnWidths = ";0": Rem optional, can be set at design time
.BoundColumn = 2: Rem design time
.TextColumn = 1: Rem design time
.List = Range("l3:M8").Value
End With
End Sub
Private Sub UserForm_Initialize()
With who
.ColumnCount = 2: Rem can be set at design time
.ColumnWidths = ";0": Rem optional, can be set at design time
.BoundColumn = 2: Rem design time
.TextColumn = 1: Rem design time
.List = Range("J3:K6").Value
End With
With kind
.ColumnCount = 2: Rem can be set at design time
.ColumnWidths = ";0": Rem optional, can be set at design time
.BoundColumn = 2: Rem design time
.TextColumn = 1: Rem design time
.List = Range("l3:M8").Value
End With
end SUB