lorena
Centurion
I have a very long webform to be used for insurance changes. I have a series of radio buttons within each section (Medical, Dental, Life Ins, etc) which users click to indicate which type of change they want to make. With Medical it's no problem, we have one type of Medical and it will be for the employee or employee and family.
With Dental, however, I have the radio buttons, two checkboxes and a dropdown. I need to figure out a way to make sure, if the user selected "Add" for the Dental portion, that they also check at least one checkbox and make a selection from the dropdown.
I am probably overthinking it, but I am having a problem figuring out how to do this. Here is what I have so far (dentalBoolean is modulelevel):
Is there a way to use Try/Catch here? I want the form to cease processing if the user choices aren't correct.
sorry to be so wordy.
thanks in advance.
With Dental, however, I have the radio buttons, two checkboxes and a dropdown. I need to figure out a way to make sure, if the user selected "Add" for the Dental portion, that they also check at least one checkbox and make a selection from the dropdown.
I am probably overthinking it, but I am having a problem figuring out how to do this. Here is what I have so far (dentalBoolean is modulelevel):
Visual Basic:
Sub Check_Dental_Choices()
Dim dFlag As Boolean
'Check to see if any Dental selections have been made
If noDentalRadiobutton.Checked = False Then
If (empDentalCheckBox.Checked = True Or depDentalCheckBox.Checked = True) _
And dentalDropDownList.SelectedValue <> "Coverage Type" Then
dentalBoolean = True
Else
dFlag = False
End If
Else
'If this NoDental is the choice, all other choices are
'disregarded and dentalBoolean is set to false
dentalBoolean = False
End If
End Sub
sorry to be so wordy.
thanks in advance.