老师,
这样写哪里不对,提示
.NET Framework 版本:2.0.50727.3053
Foxtable 版本:2015.11.11.1
错误所在事件:窗口,AS003会计科目,AfterLoad
详细错误信息:
未将对象引用设置到对象的实例。
Dim drs As List(Of DataRow)
Dim kmlx As List(Of String)
Dim I As Integer
Dim pg As WinForm.TabPage
Dim chk As WinForm.CheckBox=Forms("AS004账套信息").Controls("CK_按照行业性质预制科目")
If chk.Checked=True Then
Dim gslx As WinForm.ComboBox = Forms("AS004账套信息").Controls("CB_AS004账套信息.公司类型ID")
Dim gs() As String=gslx.text.Split(" ")
drs = DataTables("AS003会计科目").Select("[公司类型ID] = '"& gs(0) &"'")
kmlx=DataTables("AS003会计科目").GetValues("科目类别","[公司类型ID]='"& gs(0) &"'")
For i=0 To DataTables("AS003会计科目").GetValues("科目类别","[公司类型ID]='"& gs(0) &"'").Count-1
pg = Forms("AS004账套信息").Controls("TAB_AS004账套信息").TabPages(i) ‘难道这里页面没有被选中?
pg.Visible = True
pg.Text=kmlx(i)
Next
Else
.......
End If