Dim cj As WinForm.ComboBox = e.Form.Controls("厂家")
Dim wlmc As WinForm.ComboBox = e.Form.Controls("物料名称")
Dim wlbh As WinForm.TextBox = e.Form.Controls("物料编号")
Dim xhgg As WinForm.TextBox = e.Form.Controls("型号规格")
Dim filter As String = "1=1"
If cj.text > "" Then
filter &= " and 供货厂家 = '" & cj.Text & "'"
End If
If wlmc.text > "" Then
filter &= " and 物料名称 Like '*" & wlmc.Text & "*' "
End If
If wlbh.text > "" Then
filter &= " and 物料编号 Like '*" & wlbh.Text & "*' "
End If
If xhgg.text > "" Then
filter &= " and 型号规格 Like '*" & xhgg.Text & "*'"
End If
Tables("物料信息表").Filter = filter