Dim Filter As String = "1=1"
With e.Form.Controls("comboBox1")
If .Value IsNot Nothing Then
Filter &= " and 批次 = '" & .Value & "'"
End If
End With
With e.Form.Controls("comboBox15")
If .Value IsNot Nothing Then
Filter &= " and 年度 = '" & .Value & "'"
End If
End With
With e.Form.Controls("comboBox16")
If .Value IsNot Nothing Then
Filter &= " and 姓名 = '" & .Value & "'"
End If
End With
With e.Form.Controls("comboBox01")
If .Value IsNot Nothing Then
Filter &= " and 鉴定类别 = '" & .Value & "'"
End If
End With
If e.Form.Controls("yjd").Checked = True ' 如果付款状态选择了"已付"
Filter = Filter & " and 是否鉴定 = true"
End If
If e.Form.Controls("wjd").Checked = True ' 如果付款状态选择了"未付"
Filter = Filter & " and 是否鉴定 = false"
End If
msgbox(filter)
If Filter > "" Then
Dim str As String = Tables("劳动能力鉴定_鉴定").DataTable.GetComboListString("_Identify", filter)
Tables("劳动能力鉴定_鉴定").Filter = "_Identify in (" & str.replace("|", ",") & ")"
End If
'Tables("劳动能力鉴定_鉴定").Sort = "编号"