以文本方式查看主题

-  Foxtable(狐表)  (http://foxtable.com/bbs/index.asp)
--  专家坐堂  (http://foxtable.com/bbs/list.asp?boardid=2)
----  [求助]老师看看,这行代码如何写,这个NOT IN 不会用  (http://foxtable.com/bbs/dispbbs.asp?boardid=2&id=149014)

--  作者:huangfanzi
--  发布时间:2020/4/21 11:44:00
--  [求助]老师看看,这行代码如何写,这个NOT IN 不会用
Dim tb As Table = Tables(_jzsbm)
Dim ccb As WinForm.CheckedComboBox = e.Form.Controls("CheckedComboBox")
Dim s As String
For Each c As Col In tb.Cols
    If c.Name & " NOT In (\'备注\',\'录入人\',\'录入时间\',\'首审记录\',\'末审记录\')"  Then       
        s = s & "|" & c.Name
    End If
Next

ccb.ComboList = s


--  作者:有点蓝
--  发布时间:2020/4/21 12:04:00
--  
代码没有NOT In这种用法,那是表达式才有的。

Dim tb As Table = Tables(_jzsbm)
Dim ccb As WinForm.CheckedComboBox = e.Form.Controls("CheckedComboBox")
Dim s As String
For Each c As Col In tb.Cols
select case c.Name
    case "备注","录入人","录入时间","首审记录","末审记录"
case else 
        s = s & "|" & c.Name
    End select
Next