以文本方式查看主题

-  Foxtable(狐表)  (http://foxtable.com/bbs/index.asp)
--  专家坐堂  (http://foxtable.com/bbs/list.asp?boardid=2)
----  多选框的问题  (http://foxtable.com/bbs/dispbbs.asp?boardid=2&id=77068)

--  作者:yongxuanchen
--  发布时间:2015/11/10 16:03:00
--  多选框的问题

.NET Framework 版本:2.0.50727.3655
Foxtable 版本:2015.11.2.1
错误所在事件:窗口,自检记录信息,CheckBox9,CheckedChanged
详细错误信息:
System.NullReferenceException: Object reference not set to an instance of an object.
   at UserCode.A2aPFSSzWOdp9QrlM(ControlEventArgs e)

 

系统报错如上面。程序中CheckBox9绑定了玻璃门结论,CheckedChanged中写入了程序:If e.Sender.Checked=True Then
     Tables("电梯信息表") .Current.DataRow("玻璃门")="符合"
Else
   Tables("电梯信息表") .Current.DataRow("玻璃门")="/"
End If

操作了不同的字段,是不是出现了冲突,谢谢!另外几个多选框同样具有这个问题,系统同样报错。


--  作者:大红袍
--  发布时间:2015/11/10 16:05:00
--  
If  Tables("电梯信息表") .Current Is Nothing Then
    msgbox("表没有数据")
Else
    If e.Sender.Checked=True Then
        Tables("电梯信息表") .Current.DataRow("玻璃门")="符合"
    Else
        Tables("电梯信息表") .Current.DataRow("玻璃门")="/"
    End If
End If