以文本方式查看主题 - Foxtable(狐表) (http://foxtable.net/bbs/index.asp) -- 专家坐堂 (http://foxtable.net/bbs/list.asp?boardid=2) ---- 以下是自己做的筛选窗口,如何实现满足多条件筛选 (http://foxtable.net/bbs/dispbbs.asp?boardid=2&id=21028) |
||||||||
-- 作者:02010993 -- 发布时间:2012/6/27 20:42:00 -- 以下是自己做的筛选窗口,如何实现满足多条件筛选 单一条件中的多项可以实现筛选,如何实现条件1+条件2+条件3同时满足的代码。跪求大侠帮助~~~~ 给点灵感,谢谢!!!
|
||||||||
-- 作者:y2287958 -- 发布时间:2012/6/27 21:50:00 -- Dim s As String Dim s1 As String() = {e.Form.Controls("bm").Value,e.Form.Controls("xb").Value,e.Form.Controls("ht").Value,e.Form.Controls("zc").Value} Dim s2 As String() = {"第二列","第四列","第五列","第六列"} For i As Integer = 0 To s1.Length-1 If s1(i) Is Nothing Continue For End If s = s & " And " & s2(i) & " In (\'" & s1(i).Replace(",","\',\'") & "\')" Next If s > "" Tables("表A").Filter = s.TrimStart(" ","A","n","d"," ") End If |
||||||||
-- 作者:02010993 -- 发布时间:2012/6/27 22:27:00 -- 非常感谢y2287958, |