kabushnell
Technical User
I think this is fairly simple and I can't quite get it. I have a form that opens in Excel when a macro is ran. When the form opens, the user must select one of three radio buttons and may choose up to five checkboxes. When the user chooses one of the radio buttons and a combination of checkboxes text needs to be inserted into cell D1. I can't quite figure out the code to get the text to populate when the OK button is selected. Here is what I have for the form coding so far.
Private Sub cmdCancel_Click()
Unload Me
End Sub
Private Sub cmdOK_Click()
Dim strParagraph As String
'One radio button must be selected'
If radW2 = False Or rad415 = False Or rad3401 = False Then
MsgBox ("Please choose one of the three compensation types"), vbOKOnly, "Error"
If radW2 = True Then strParagraph = "Total W-2 Compensation"
End Sub
Private Sub cmdCancel_Click()
Unload Me
End Sub
Private Sub cmdOK_Click()
Dim strParagraph As String
'One radio button must be selected'
If radW2 = False Or rad415 = False Or rad3401 = False Then
MsgBox ("Please choose one of the three compensation types"), vbOKOnly, "Error"
If radW2 = True Then strParagraph = "Total W-2 Compensation"
End Sub