以文本方式查看主题

-  Foxtable(狐表)  (http://www.foxtable.com/bbs/index.asp)
--  专家坐堂  (http://www.foxtable.com/bbs/list.asp?boardid=2)
----  逻辑值  (http://www.foxtable.com/bbs/dispbbs.asp?boardid=2&id=46484)

--  作者:发财
--  发布时间:2014/2/24 16:17:00
--  逻辑值
    For Each t2 As Row In Tables("收购.销售")
        If t2("重量")  Is Nothing Then
            t2("修改") = True
         Else
            t2("修改") = False
        End If
    Next
为什么重量为空值或不为零时,修改的逻辑值都选为true呢?
--  作者:狐狸爸爸
--  发布时间:2014/2/24 16:18:00
--  

   If t2("重量")  Is Nothing Then

 

改为:

 

   If t2.Isnull("重量")  Then


--  作者:狐狸爸爸
--  发布时间:2014/2/24 16:19:00
--  

原因帮助有说明:

 

http://www.foxtable.com/help/topics/1470.htm

 


--  作者:Bin
--  发布时间:2014/2/24 16:19:00
--  
For Each t2 As Row In Tables("收购.销售")
        If t2("重量")  Is Nothing OrElse t2("重量")=0 Then
            t2("修改") = True
         Else 
            t2("修改") = False
        End If
    Next