Android Question who tell me about this error?

hf

Member
Licensed User
java.lang.NullPointerException: Attempt to read from field 'anywheresoftware.b4a.objects.ActivityWrapper b4a.smqy.smqy._activity' on a null object reference
at b4a.smqy.smqy$ResumeMessage.run(smqy.java:302)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:5441)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:738)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:628)
 

Cableguy

Expert
Licensed User
Longtime User
It seems you are trying to access something not yet initialized
 
Upvote 0

hf

Member
Licensed User
just on debug, occur error.
on realease, b4a log such as :

PackageAdded: package:b4a.smqy
*** Service (starter) Create ***
** Service (starter) Start **
** Activity (main) Create, isFirst = true **
** Activity (main) Resume **
** Activity (main) Pause, UserClosed = true **
** Activity (login) Create, isFirst = true **
** Activity (login) Resume **
** Activity (login) Pause, UserClosed = true **
** Activity (hfxf) Create, isFirst = true **
** Activity (hfxf) Resume **
** Activity (hfxf) Pause, UserClosed = false **
** Activity (smqy) Create, isFirst = true **
** Activity (smqy) Resume **
** Activity (smqy) Pause, UserClosed = false **
Portrait
Screen 1080 1920
CODE_392017082900024###myzx_result
sending message to waiting queue (OnActivityResult)
running waiting messages (1)
** Activity (smqy) Resume **
** Activity (smqy) Pause, UserClosed = false **
Portrait
CODE_392017082900024###myzx_result
sending message to waiting queue (OnActivityResult)
running waiting messages (1)
** Activity (smqy) Resume **
** Activity (smqy) Pause, UserClosed = false **
Portrait
CODE_392017082900024###myzx_result
sending message to waiting queue (OnActivityResult)
running waiting messages (1)
** Activity (smqy) Resume **
** Activity (smqy) Pause, UserClosed = false **
Portrait
CODE_392017082900024###myzx_result
sending message to waiting queue (OnActivityResult)
running waiting messages (1)
** Activity (smqy) Resume **
** Activity (smqy) Pause, UserClosed = false **
Portrait
CODE_392017082900028###myzx_result
*** Service (starter) Create ***
** Service (starter) Start **
** Activity (hfxf) Create, isFirst = true **
** Activity (hfxf) Resume **

the red part, is error ,should "sending message to waiting queue (OnActivityResult) running waiting messages (1)..."
 
Upvote 0

hf

Member
Licensed User
this is source code
 

Attachments

  • Screenshot_2017-08-03-14-13-57-786_b4a.smqy.png
    118.5 KB · Views: 191
  • smqy.bas
    6.5 KB · Views: 245
  • smqy.bal
    9.2 KB · Views: 169
Upvote 0

hf

Member
Licensed User
Please use File - Export as zip to create a zip with all required files.

Note that you should create a single Beeper object and reuse it or call Beeper.Release when you are done with it.


I think the error is "JhsIceZxing lib scanbarcode have bug, it scan result wrong when it scan long time"
 
Upvote 0

hf

Member
Licensed User
Please use File - Export as zip to create a zip with all required files.

Note that you should create a single Beeper object and reuse it or call Beeper.Release when you are done with it.


you can scan the barcode of the picture,then the error occur, so the lib " JhsIceZxing1" have bugs,can you solve? help me?
 
Upvote 0

hf

Member
Licensed User
Only the library developer can help you if there is a bug inside the library. However there are several other barcode libraries available...


thanks, I find this lib is well for me, but have bugs. other barcode libraries ? can you give me a list of other barcode libraries ? I try to use it.
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…