Hi to all
edit in userform-combobox
if cat insert in cell B10 cat
if dog insert in cell B11 dog
if bird insert in cell B12 bird
thank you
edit in userform-combobox
VBA Code:
Option Explicit
Private Sub cmdCancel_Click()
'Unload the userform
Unload Me
End Sub
Private Sub cmdOkay_Click()
'Verify that an item was selected
If Me.ComboBox1.BoundValue = vbNullString Then
MsgBox "You did not choose an item!", vbOKOnly
Else
MsgBox "You choose " & Me.ComboBox1.BoundValue, vbOKOnly
End If
Unload Me
End Sub
Private Sub UserForm_Initialize()
'Load the combobox with a variety of household pets
With Me.ComboBox1
.AddItem ("Cat")
.AddItem ("Dog")
.AddItem ("Bird")
End With
End Sub
if cat insert in cell B10 cat
if dog insert in cell B11 dog
if bird insert in cell B12 bird
thank you