G
Guest
Is the code below correct?
I have two radio buttons within an option group (ImportOption). I have a
button, to which this code is executed when clicked.
I always receive the error message no matter which button is selected. On
debugging 'ImportOption' is empty.
Can anyone help me please?
Thanks.
Function importMethod_Click()
Select Case ImportOption
Case 1
MsgBox "Option 1."
Case 2
MsgBox "Option 2."
Case Else
MsgBox "Please select an option."
GoTo exit_importMethod_Click
End Select
exit_importMethod_Click:
Exit Function
End Function
I have two radio buttons within an option group (ImportOption). I have a
button, to which this code is executed when clicked.
I always receive the error message no matter which button is selected. On
debugging 'ImportOption' is empty.
Can anyone help me please?
Thanks.
Function importMethod_Click()
Select Case ImportOption
Case 1
MsgBox "Option 1."
Case 2
MsgBox "Option 2."
Case Else
MsgBox "Please select an option."
GoTo exit_importMethod_Click
End Select
exit_importMethod_Click:
Exit Function
End Function