.NET Framework 版本:4.0.30319.42000
Foxtable 版本:2022.8.18.1
错误所在事件:窗口,丝印网管理,Button1,Click
详细错误信息:
未将对象引用设置到对象的实例。
Dim cmd As SQLCommand
cmd.CommandText = "sele ct a.*,b.* from {SYWZB} as a left join {SYWMX} as b on a.WZItid = b.WZItid"
Dim tb As Table = Tables(e.Form.Name & "_table1")
Dim dt As DataTable = tb.DataTable
tb.DataSource = cmd.ExecuteReader
Dim cmd As new SQLCommand
cmd.CommandText = "sele ct a.*,b.* from {SYWZB} as a left join {SYWMX} as b on a.WZItid = b.WZItid"
Dim tb As Table = Tables(e.Form.Name & "_table1")
tb.DataSource = cmd.ExecuteReader
内部表不能使用sql新增,更改数据,只能使用sql查询。否则可能会导致项目文件损坏