Bug? Debugger exits after installing (activity not initialized)

pixsys

Member
Licensed User
Longtime User
Hello, just upgraded from 3.5 to 5.8.
For some reason, i can't run the debugger anymore. I can install and run Release versions just fine, without any errors, but the debugger installs the app, goes into "waiting for ide..." and then leaves the foreground after a few seconds, out putting this log:

B4X:
:null,0
java.lang.RuntimeException: Object should first be initialized (Activity).
Did you forget to call Activity.LoadLayout?
I just updated, so no starter service(or the newest additions) yet...
B4X:
Sub Globals
        Dim TabHost1 As TabHost
...

Sub Activity_Create(FirstTime As Boolean)   
    Activity.LoadLayout("guihost")   
    TabHost1.AddTab("1", "splash")
    TabHost1.AddTab("2", "Layout1")
    TabHost1.AddTab("3", "Layout2")
    TabHost1.AddTab("4", "Layout3")
.....

Thanks
 

DonManfred

Expert
Licensed User
Longtime User
For some reason, i can't run the debugger anymore. I can install and run Release versions just fine, without any errors, but the debugger installs the app, goes into "waiting for ide..." and then leaves the foreground after a few seconds, out putting this log
when your last installation of your app is made during releasemode the app does not need the debugger.
If you compile it using debugger (it is per default the rapid debugger) you cant start you app manually. You can switch to the legacy debugger which is found in the Menu.
 

pixsys

Member
Licensed User
Longtime User
Thanks alot for the replies, the legacy debugger is indeed still working (didnt see it in the spinner so i thought it got removed entirely from the last builds)

For the .net i just checked and think i'm still on 4.0.3 :confused:.. i'll update asap and see if it solves my issue with the rapid debugger
 

pixsys

Member
Licensed User
Longtime User
Thanks for all the replies, i found the problem, had a
B4X:
Dim MarginVisible As Int  = Activity.Width
buried somewhere in Process_Globals :eek:

Which i suppose is wrong because the debugger might not know the width of the layout at that point of execution, hence the "Did you forget to call Activity.LoadLayout?" message.

Not sure why only rapid debugger was affected thou, while release and legacy worked without problems.
 
Last edited:
Top