Android Question HttpJob.Download2 => java.lang.NullPointerException

Facilauto Juan

Member
Licensed User
Longtime User
Hello there!

I'm trying to retrieve data from my database using download2 method in HttpJob class. But I get this error:

B4X:
job.Download2("http://fxxx.php", Array As String("c", s))
java.lang.NullPointerException


    at anywheresoftware.b4a.samples.httputils2.httpjob._download2(httpjob.java:104)
    at testbook.facilauto.contenidosmostrar._ejecuta_sql(contenidosmostrar.java:1114)
    at testbook.facilauto.contenidosmostrar._pontextocontenidos(contenidosmostrar.java:1263)
    at testbook.facilauto.contenidosmostrar._actualizacontenido(contenidosmostrar.java:377)
    at testbook.facilauto.contenidosmostrar._cargainicio(contenidosmostrar.java:685)
    at testbook.facilauto.contenidosmostrar._activity_create(contenidosmostrar.java:275)
    at java.lang.reflect.Method.invokeNative(Native Method)
    at java.lang.reflect.Method.invoke(Method.java:511)
    at anywheresoftware.b4a.BA.raiseEvent2(BA.java:169)
    at testbook.facilauto.contenidosmostrar.afterFirstLayout(contenidosmostrar.java:89)
    at testbook.facilauto.contenidosmostrar.access$100(contenidosmostrar.java:16)
    at testbook.facilauto.contenidosmostrar$WaitForLayout.run(contenidosmostrar.java:74)
    at android.os.Handler.handleCallback(Handler.java)


    at android.os.Handler.dispatchMessage(Handler.java)
    at android.os.Looper.loop(Looper.java)
    at android.app.ActivityThread.main(ActivityThread.java)
    at java.lang.reflect.Method.invokeNative(Native Method)
    at java.lang.reflect.Method.invoke(Method.java:511)
    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java)
    at dalvik.system.NativeStart.main(Native Method)

What am I doing wrong?

Thanks in advance for all the help.
 
Top