Hi,
after upgrading to B4A 6.8 I have a problem with loading a Layout File.
The Log says: Object should first be initialized (ScrollView).
I do not access the ScrollView in the code, I´m just loading the layout.
It worked in earlier Versions. I have the impression that the new B4A damaged the LayoutFile.
Is that possible?
Any Help is much appreciated.
An extracted Version of the App is attached, so maybe someone has an idea where the problem comes from.
That is the relevant Code:
The Error occurs on line 26 wich is the: Activity.LoadLayout("pgmain")
after upgrading to B4A 6.8 I have a problem with loading a Layout File.
The Log says: Object should first be initialized (ScrollView).
I do not access the ScrollView in the code, I´m just loading the layout.
It worked in earlier Versions. I have the impression that the new B4A damaged the LayoutFile.
Is that possible?
Any Help is much appreciated.
An extracted Version of the App is attached, so maybe someone has an idea where the problem comes from.
That is the relevant Code:
B4X:
Sub Activity_Create(FirstTime As Boolean)
Activity.LoadLayout("pgmain")
End Sub
The Error occurs on line 26 wich is the: Activity.LoadLayout("pgmain")
B4X:
Error occurred on line: 26 (Main)
java.lang.RuntimeException: java.lang.RuntimeException: Object should first be initialized (ScrollView).
at anywheresoftware.b4a.keywords.LayoutBuilder.loadLayout(LayoutBuilder.java:166)
at anywheresoftware.b4a.objects.ActivityWrapper.LoadLayout(ActivityWrapper.java:209)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at anywheresoftware.b4a.shell.Shell.runMethod(Shell.java:710)
at anywheresoftware.b4a.shell.Shell.raiseEventImpl(Shell.java:342)
at anywheresoftware.b4a.shell.Shell.raiseEvent(Shell.java:249)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at anywheresoftware.b4a.ShellBA.raiseEvent2(ShellBA.java:134)
at b4a.example.main.afterFirstLayout(main.java:102)
at b4a.example.main.access$000(main.java:17)
at b4a.example.main$WaitForLayout.run(main.java:80)
at android.os.Handler.handleCallback(Handler.java:733)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:136)
at android.app.ActivityThread.main(ActivityThread.java:5476)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1283)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1099)
at dalvik.system.NativeStart.main(Native Method)
Caused by: java.lang.RuntimeException: Object should first be initialized (ScrollView).
at anywheresoftware.b4a.AbsObjectWrapper.getObject(AbsObjectWrapper.java:50)
at anywheresoftware.b4a.objects.ViewWrapper.innerInitialize(ViewWrapper.java:71)
at anywheresoftware.b4a.objects.ScrollViewWrapper.innerInitialize(ScrollViewWrapper.java:59)
at anywheresoftware.b4a.keywords.LayoutBuilder.loadLayoutHelper(LayoutBuilder.java:406)
at anywheresoftware.b4a.keywords.LayoutBuilder.loadLayoutHelper(LayoutBuilder.java:425)
at anywheresoftware.b4a.keywords.LayoutBuilder.loadLayout(LayoutBuilder.java:144)
... 21 more
** Activity (main) Resume **