Android Question panel name -> main ?

ilan

Expert
Licensed User
Longtime User
hi

i am not sure if it is a bug or it is intended to be like this but calling a panel "main" will crash the app when trying to load the layout
 

ilan

Expert
Licensed User
Longtime User
Can you post the error message?
sure

B4X:
Copying updated assets files (1)
*** Service (starter) Create ***
** Service (starter) Start **
** Activity (main) Create (first time) **
*** mainpage: B4XPage_Created
Error occurred on line: 25 (B4XMainPage)
java.lang.RuntimeException: java.lang.ClassCastException: java.lang.Class cannot be cast to java.lang.reflect.ParameterizedType
    at anywheresoftware.b4a.keywords.LayoutBuilder.loadLayout(LayoutBuilder.java:155)
    at anywheresoftware.b4a.objects.PanelWrapper.LoadLayout(PanelWrapper.java:134)
    at anywheresoftware.b4a.objects.B4XViewWrapper.LoadLayout(B4XViewWrapper.java:329)
    at java.lang.reflect.Method.invoke(Native Method)
    at anywheresoftware.b4a.shell.Shell.runMethod(Shell.java:732)
    at anywheresoftware.b4a.shell.Shell.raiseEventImpl(Shell.java:351)
    at anywheresoftware.b4a.shell.Shell.raiseEvent(Shell.java:255)
    at java.lang.reflect.Method.invoke(Native Method)
    at anywheresoftware.b4a.ShellBA.raiseEvent2(ShellBA.java:157)
    at anywheresoftware.b4a.debug.Debug.delegate(Debug.java:262)
    at www.sagital.xoand.b4xmainpage._b4xpage_created(b4xmainpage.java:64)
    at java.lang.reflect.Method.invoke(Native Method)
    at anywheresoftware.b4a.debug.Debug.CallSub4(Debug.java:318)
    at anywheresoftware.b4a.debug.Debug.CallSubNew2(Debug.java:285)
    at java.lang.reflect.Method.invoke(Native Method)
    at anywheresoftware.b4a.keywords.Common.CallSubDebug2(Common.java:1087)
    at www.sagital.xoand.b4xpagesmanager._createpageifneeded(b4xpagesmanager.java:1068)
    at www.sagital.xoand.b4xpagesmanager._showpage(b4xpagesmanager.java:425)
    at www.sagital.xoand.b4xpagesmanager._addpage(b4xpagesmanager.java:245)
    at www.sagital.xoand.b4xpagesmanager._addpageandcreate(b4xpagesmanager.java:259)
    at www.sagital.xoand.b4xpagesmanager._initialize(b4xpagesmanager.java:165)
    at www.sagital.xoand.main._activity_create(main.java:415)
    at java.lang.reflect.Method.invoke(Native Method)
    at anywheresoftware.b4a.shell.Shell.runMethod(Shell.java:732)
    at anywheresoftware.b4a.shell.Shell.raiseEventImpl(Shell.java:351)
    at anywheresoftware.b4a.shell.Shell.raiseEvent(Shell.java:255)
    at java.lang.reflect.Method.invoke(Native Method)
    at anywheresoftware.b4a.ShellBA.raiseEvent2(ShellBA.java:157)
    at www.sagital.xoand.main.afterFirstLayout(main.java:105)
    at www.sagital.xoand.main.access$000(main.java:17)
    at www.sagital.xoand.main$WaitForLayout.run(main.java:83)
    at android.os.Handler.handleCallback(Handler.java:958)
    at android.os.Handler.dispatchMessage(Handler.java:99)
    at android.os.Looper.loopOnce(Looper.java:205)
    at android.os.Looper.loop(Looper.java:294)
    at android.app.ActivityThread.main(ActivityThread.java:8177)
    at java.lang.reflect.Method.invoke(Native Method)
    at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:552)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:971)
Caused by: java.lang.ClassCastException: java.lang.Class cannot be cast to java.lang.reflect.ParameterizedType
    at anywheresoftware.b4a.keywords.LayoutBuilder.loadLayoutHelper(LayoutBuilder.java:396)
    at anywheresoftware.b4a.keywords.LayoutBuilder.loadLayoutHelper(LayoutBuilder.java:442)
    at anywheresoftware.b4a.keywords.LayoutBuilder.loadLayout(LayoutBuilder.java:133)
    ... 38 more
*** mainpage: B4XPage_Appear
** Activity (main) Resume **
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…