以文本方式查看主题

-  Foxtable(狐表)  (http://foxtable.com/bbs/index.asp)
--  专家坐堂  (http://foxtable.com/bbs/list.asp?boardid=2)
----  Filter出来的结果修改后会再过滤掉  (http://foxtable.com/bbs/dispbbs.asp?boardid=2&id=120073)

--  作者:蓝蚂蚁
--  发布时间:2018/6/6 15:22:00
--  Filter出来的结果修改后会再过滤掉
窗口按钮代码:
说明:对窗口1中的副本表进行筛选
Dim str1 As String="江西"
Tables("窗口1_Table1").filter="地点=\'"&  str1  &"\' and 标记=false  and [备注] is null"


问题:当我把筛选出来的数据,在备注列输入内容后,回车,该行马上就隐藏不见了,如何修改代码,使之不再次筛选。

--  作者:有点甜
--  发布时间:2018/6/6 15:46:00
--  

 Dim str1 As String="江西"
Dim ids = "-1,"
ids = Tables("窗口1_Table1").DataTable.GetComboListString("_Identify","地点=\'"&  str1  &"\' and 标记=false  and [备注] is null")
ids = ids.replace("|", ",").trim(",")
Tables("窗口1_Table1").filter = "_Identify in (" & ids & ")"

[此贴子已经被作者于2018/6/6 15:46:01编辑过]

--  作者:蓝蚂蚁
--  发布时间:2018/6/6 21:30:00
--  

图片点击可在新窗口打开查看此主题相关图片如下:image 1.jpg
图片点击可在新窗口打开查看

提示的错误:语法错误: IN 关键字后面必须是由逗号分隔的非空表达式列表,并且必须用括号括起来。

--  作者:有点甜
--  发布时间:2018/6/6 21:36:00
--  

Dim str1 As String="江西"
Dim ids = "-1,"
ids &= Tables("窗口1_Table1").DataTable.GetComboListString("_Identify","地点=\'"&  str1  &"\' and 标记=false  and [备注] is null")
ids = ids.replace("|", ",").
trim(",")
Tables("窗口1_Table1").filter = "_Identify in (" & ids & ")"

[此贴子已经被作者于2018/6/6 21:36:25编辑过]

--  作者:蓝蚂蚁
--  发布时间:2018/6/6 21:59:00
--  
谢谢 完美解决