以文本方式查看主题

-  Foxtable(狐表)  (http://foxtable.net/bbs/index.asp)
--  专家坐堂  (http://foxtable.net/bbs/list.asp?boardid=2)
----  [求助]请教Filter  (http://foxtable.net/bbs/dispbbs.asp?boardid=2&id=73106)

--  作者:农村人
--  发布时间:2015/8/12 15:41:00
--  [求助]请教Filter

Dim ls As String = e.sender.value

Dim ls1 As String = "KR05-1166001"

 

Dim t As Table = Tables("质检_Table1")
With Tables("质检_Table1")
    t.Filter = "序号 = \'" & ls & "\'"         \' 能否同时筛选出既包含 ls 又包含 ls1 这两个条件?
End With


--  作者:jialihaha
--  发布时间:2015/8/12 15:43:00
--  

Dim ls As String = e.sender.value

Dim ls1 As String = "KR05-1166001"

 

Dim t As Table = Tables("质检_Table1")
With Tables("质检_Table1")
    t.Filter = "序号 = \'" & ls & "\' or 序号 = \'" &  
ls1 & "\'"        

End With

[此贴子已经被作者于2015/8/12 15:43:57编辑过]

--  作者:有点蓝
--  发布时间:2015/8/12 15:45:00
--  
t.Filter = "序号 = ‘" & ls & "\' Or 序号=\'" & ls1 & "\'"