Hello all
here is my situation
I have a total of 7 check buttons on a form. The first 6 are grouped together in an array. The user can select any or all of these buttons. The 7'th button is selected when the user wants none of the above. Here is my problem. When the user enters the form and selects none of the above each of the first 6 buttons has a value of unchecked and the 7'th button a value of vbchecked. But, when the user first selects 1 or more the first 6 then changes their mind and selects none of the above I can not get the value of the 7'th to be vbchecked. The problem lies in tha fact that when the user selects none of the above I set the value of each of the first 6 to vbchecked. This calls the click event of the first 6 to be executed. In there I have a line that sets the none above value to unchecked.
Any thoughts here is my code, so for the lon winded explanation.
'code for none of the above
Private Sub chkNoneAbove_Click()
Dim icounter As Integer
'clear buttons if none of the a bove is choosen
For icounter = 0 To 5
chkQ5(icounter).Value = Unchecked
Next icounter
end sub
'code for 6 buttons
Private Sub chkQ5_Click(Index As Integer)
chkNoneAbove.Value = Unchecked
End Sub
here is my situation
I have a total of 7 check buttons on a form. The first 6 are grouped together in an array. The user can select any or all of these buttons. The 7'th button is selected when the user wants none of the above. Here is my problem. When the user enters the form and selects none of the above each of the first 6 buttons has a value of unchecked and the 7'th button a value of vbchecked. But, when the user first selects 1 or more the first 6 then changes their mind and selects none of the above I can not get the value of the 7'th to be vbchecked. The problem lies in tha fact that when the user selects none of the above I set the value of each of the first 6 to vbchecked. This calls the click event of the first 6 to be executed. In there I have a line that sets the none above value to unchecked.
Any thoughts here is my code, so for the lon winded explanation.
'code for none of the above
Private Sub chkNoneAbove_Click()
Dim icounter As Integer
'clear buttons if none of the a bove is choosen
For icounter = 0 To 5
chkQ5(icounter).Value = Unchecked
Next icounter
end sub
'code for 6 buttons
Private Sub chkQ5_Click(Index As Integer)
chkNoneAbove.Value = Unchecked
End Sub