Hello Erel!
In B4J 8.10 I was able to initialize global b4Xview variables like this
but starting from B4J 8.30 it throws error "java.lang.RuntimeException: Object should first be initialized (B4XView)." at lbl.Text="new text".
Is it a bug or I'm doing something wrong?
In B4J 8.10 I was able to initialize global b4Xview variables like this
test:
Sub Process_Globals
Private fx As JFX
Private MainForm As Form
Private xui As XUI
Private lbl As B4XView
End Sub
Sub AppStart (Form1 As Form, Args() As String)
MainForm = Form1
MainForm.Show
MainForm.RootPane.AddNode(makelbl(lbl),0,0,100,100)
lbl.Text="new text"
End Sub
Sub makelbl(bx As B4XView) As B4XView
Dim l As Label
l.Initialize("")
bx=l
l.Text="test"
Return bx
End Sub
but starting from B4J 8.30 it throws error "java.lang.RuntimeException: Object should first be initialized (B4XView)." at lbl.Text="new text".
Is it a bug or I'm doing something wrong?