Android Question Unexpected exception at pgm start

Diceman

Active Member
Licensed User
I made one change to my B4A app v9.50 and I get this exception when program starts.

java.lang.RuntimeException: Unable to create service b4a.example.starter: java.lang.RuntimeException: java.io.EOFException
at android.app.ActivityThread.handleCreateService(ActivityThread.java:3965)
at android.app.ActivityThread.access$1500(ActivityThread.java:219)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1875)
at android.os.Handler.dispatchMessage(Handler.java:107)
at android.os.Looper.loop(Looper.java:214)
at android.app.ActivityThread.main(ActivityThread.java:7356)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:492)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:930)
Caused by: java.lang.RuntimeException: java.io.EOFException
at anywheresoftware.b4a.shell.Shell.virtualAssets(Shell.java:164)
at anywheresoftware.b4a.shell.Shell.start(Shell.java:102)
at anywheresoftware.b4a.ShellBA.raiseEvent2(ShellBA.java:92)
at b4a.example.starter.onCreate(starter.java:34)
at android.app.ActivityThread.handleCreateService(ActivityThread.java:3953)
... 8 more
Caused by: java.io.EOFException
at java.io.DataInputStream.readFully(DataInputStream.java:200)
at java.io.DataInputStream.readInt(DataInputStream.java:389)
at anywheresoftware.b4a.shell.Shell.virtualAssets(Shell.java:136)
... 12 more

The change I made was to add the following line to Globals:
Private lblSeekBar As Label

If I uncomment this line, it runs without the error. Or if I use the Legacy Debugger, it runs fine. Running Tools > Clean Project does not solve the problem.

The program has several code modules and classes and has worked fine for weeks. I was just tweaking it yesterday by adding a label to the designer layout and generating the variable reference which caused the problem. I created a test app with the label and seekbar and it works fine, just not with my app.

Any idea how I can solve the problem?
TIA
 

Diceman

Active Member
Licensed User

Thanks for the links.

I tried their suggestions:
#DebuggerForceFullDeployment: true
#DebuggerForceStandardAssets: true

and the problem is still intermittent. It may fail 10 times in a row, then the pgm will run without displaying the error. If I can't figure it out I will switch to the legacy debugger.
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…