wherestr = wherestr + " and " Else
wherestr = wherestr + " or " End If End If
wherestr = wherestr + "Class like '%" & txtClassKey & "%'" End If
'性别关键字
If frameGender1.Visible And chkGenderKey.Value = 1 Then If wherestr <> "" Then
If optnGenderand.Value Then wherestr = wherestr + " and " Else
wherestr = wherestr + " or " End If End If
If OptnMale.Value Then
wherestr = wherestr + "Gender like '%" & "男" & "%'" ElseIf OptnFemale.Value Then
wherestr = wherestr + "Gender like '%" & "女" & "%'" End If End If '入学时间
If frameTime.Visible And chkTimeKey.Value = 1 Then If optnKeyFore.Value Or optnKeyBack.Value Then
If txtYearKeyFore.Text = "" Or txtMonKeyFore.Text = "" Then
MsgBox "请完整填写查询时间!", vbOKOnly + vbInformation, "查询" Exit Sub End If
If wherestr <> "" Then
If optnTimeand.Value Then
wherestr = wherestr + " and " Else
wherestr = wherestr + " or " End If End If
If optnKeyFore Then
wherestr = wherestr + "publishtime <'" & txtYearKeyFore.Text + "-" + txtMonKeyFore.Text & "'" Else
wherestr = wherestr + "publishtime >'" & txtYearKeyFore.Text + "-" + txtMonKeyFore.Text & "'" End If
ElseIf optnKeyBetween.Value Then