不行,我有两个控件,如何实现点击控件一进行筛选后,如果再点击控件二,控件二的筛选是在控件一的基础上进行的。控件一、
Dim fi As String = Nothing
For Each f As WinForm.Control In e.Form.Controls("GroupBox2").Children
If Typeof f Is WinForm.CheckBox Then
Dim chk As WinForm.CheckBox = f
If chk.Checked = True Then
If fi > "" Then fi = fi & " and "
fi = fi & chk.Text & " = " & chk.Checked
End If
End If
Next
MessageBox.Show(fi)
Tables("排产汇总_Tab排产汇总").filter = fi
控件二。
Dim all As WinForm.RadioButton = e.Form.Controls("RadhAll")
Dim dip As WinForm.RadioButton = e.Form.Controls("RadhDip")
Dim smt As WinForm.RadioButton = e.Form.Controls("RadhSmt")
'Dim dr As Row = Tables("排产汇总_Tab订单明细").Current
Dim fi As String ' = "产品代码 = '" & dr("产品代码") & "'"
Dim tb As Table = Tables("排产汇总_Tab排产汇总")
If all.Checked = True Then fi = "工序 = 'dip' or 工序 = 'smt'"
If dip.Checked = True Then fi = "工序 = 'dip'"
If smt.Checked = True Then fi = "工序 = 'smt'"
tb.Filter = fi