以文本方式查看主题

-  Foxtable(狐表)  (http://foxtable.com/bbs/index.asp)
--  专家坐堂  (http://foxtable.com/bbs/list.asp?boardid=2)
----  [求助]帮我检查下代码有什么问题  (http://foxtable.com/bbs/dispbbs.asp?boardid=2&id=12353)

--  作者:jxjzj2000
--  发布时间:2011/8/30 17:33:00
--  [求助]帮我检查下代码有什么问题

帮我检查下,我看的都快吐了,下面代码有什么问题:

 

 

Dim Filter As String
With e.Form.Controls("发货单")
    If .checked = True Then
        Filter = Filter & "发货单 = false"
    End If
End With
With e.Form.Controls("快递单号")
    If Filter > "" Then
        Filter = Filter & " And "
    End If
    If .checked = True Then
        Filter = Filter & "快递单号 = \'0\'"
    End If
End With

 

 

运行说什么and后缺少运算符

 


--  作者:czy
--  发布时间:2011/8/30 17:49:00
--  

这样?

 

Dim Filter As String
With e.Form.Controls("发货单")
    If .checked = True Then
        Filter = Filter & "发货单 = false"
    End If
End With
With e.Form.Controls("快递单号")
    If .checked = True Then
        If Filter > "" Then
            Filter = Filter & " And 快递单号 = \'0\'"
        Else
            Filter = "快递单号 = \'0\'"
        End If
    End If
End With


--  作者:jxjzj2000
--  发布时间:2011/8/30 18:00:00
--  
原来这样,谢谢大侠,明白了,呵呵