1.将多个复选框放置在一个分组框控件中2.在分组框的Clikc事件写代码:
Dim chb1 As WinForm.CheckBox = e.Form.Controls("CheckBox1")
Dim chb2 As WinForm.CheckBox = e.Form.Controls("CheckBox2")
Dim chb3 As WinForm.CheckBox = e.Form.Controls("CheckBox3")
Static b As Boolean = True
If b Then
chb1.Checked = True
chb2.Checked = True
chb3.Checked = True
b = False
Else
chb1.Checked = False
chb2.Checked = False
chb3.Checked = False
b = True
End If