如图在 DropBox控件Enter事件中写入下面的代码,在切换到第二个或第三个页面的时候出现了代码中的提示,请教老师怎么避免这样的问题?
Dim lx As String = e.Form.Controls("ComboBox2").Value
Dim zf As Boolean = e.Form.Controls("RadioButton3").Checked
Dim ywc As Boolean = e.Form.Controls("RadioButton1").Checked
Dim wwc As Boolean = e.Form.Controls("RadioButton2").Checked
If ywc = False And wwc = False And zf = False Then
MessageBox.Show("请选择要查询的条件!")
e.Form.Controls("RadioButton2").Select()
ElseIf lx = "" Then
MessageBox.Show("请选择要查询的类型!")
e.Form.Controls("ComboBox2").Select()
End If
![dvubb 图片点击可在新窗口打开查看](skins/default/filetype/png.gif)
此主题相关图片如下:图1.png