Excel VBA UserForm Combobox Learn how to get selected item.
The source code used in this video:
Private Sub cbOK_Click()
If cbDays.ListIndex = -1 Then
MsgBox "Nothing selected"
Else
MsgBox "Selected item: " & cbDays.Value
End If
End Sub
Private Sub UserForm_Initialize()
With cbDays
.AddItem "Monday"
.AddItem "Tuesday"
.AddItem "Wednesday"
End With
End Sub