Just downloaded 2.7 beta 1, and tried compiling an app that compiled fine with 2.5x.
Got error "Object reference not set to an instance of an object." on the line that assigns to label.text below. But for the life of me, I can't figure out what's wrong.
Here's the code, which creates items to add to Informatix's clsChecklist:
I can export the source if that helps. Any help much appreciated!
Got error "Object reference not set to an instance of an object." on the line that assigns to label.text below. But for the life of me, I can't figure out what's wrong.
Here's the code, which creates items to add to Informatix's clsChecklist:
B4X:
Sub createLvItem(indexArg As Int) As Panel
Dim tempProto As proto
tempProto.Initialize
tempProto = protoList.get(indexArg) 'protoList is a global list
Dim tempPanel As Panel
tempPanel.Initialize("")
tempPanel.Color = Colors.RGB(238, 238, 238)
Dim pagesLabel As Label
pagesLabel.Initialize("")
pagesLabel.Gravity = Bit.OR(Gravity.CENTER_VERTICAL, Gravity.left)
pagesLabel.TextSize = 18
pagesLabel.TextColor = Colors.DarkGray
'pageTotal is an Int
pagesLabel.Text = tempProto.pageTotal & " pages" '<<< error
tempPanel.AddView(pagesLabel, 75%x, 0dip, 100dip, itemHeight / 2)
Return tempPanel
End Sub
I can export the source if that helps. Any help much appreciated!
Last edited: