Android Question Error reported in Firebase

vbmundo

Well-Known Member
Licensed User
Hi,

The Play Store Console only show a few ANRs in my APP, but when I go to my Firebase Console I see a lot of errors reported..

The most frequently error is that

B4X:
Exception java.lang.IndexOutOfBoundsException: Invalid index 3, size is 3
java.util.ArrayList.throwIndexOutOfBoundsException (ArrayList.java:255)
java.util.Arrays$ArrayList.get (Arrays.java:66)
anywheresoftware.b4a.objects.collections.List.Get (List.java:117)
zetoox.mysql.main._activity_create (main.java:411)
java.lang.reflect.Method.invoke (Method.java)
java.lang.reflect.Method.invoke (Method.java:372)
anywheresoftware.b4a.BA.raiseEvent2 (BA.java:169)
zetoox.mysql.main.afterFirstLayout (main.java:102)
zetoox.mysql.main.access$000 (main.java:17)
zetoox.mysql.main$WaitForLayout.run (main.java:80)
android.os.Handler.handleCallback (Handler.java:739)
android.os.Handler.dispatchMessage (Handler.java:95)
android.os.Looper.loop (Looper.java:135)
android.app.ActivityThread.main (ActivityThread.java:5910)
java.lang.reflect.Method.invoke (Method.java)
java.lang.reflect.Method.invoke (Method.java:372)
com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run (ZygoteInit.java:1405)
com.android.internal.os.ZygoteInit.main (ZygoteInit.java:1200)

But I can see in what Activity and Code Line I have this error.

How can I see in what source line appears this error ?

Regards
 

DonManfred

Expert
Licensed User
Longtime User
in a project i just tested i have had a look at the main.java...

It looks like this in the example here... Please notethe comments (// comment)

 
Upvote 0

vbmundo

Well-Known Member
Licensed User
in a project i just tested i have had a look at the main.java...

It looks like this in the example here... Please notethe comments (// comment)

yes, I hope to identify the line of error, because the main.java file is much more extensive than the Main activity of my project.

Thanks
 
Upvote 0

vbmundo

Well-Known Member
Licensed User
Incredible... this is the Fail code

B4X:
    If StateManager.RestoreState(Activity, "Main", 60) = False Then
        If File.Exists(MySQL.Carpeta,"reg5.smql")=True Then
           TextoEncriptado=File.ReadString(MySQL.Carpeta,"reg5.smql")
           Texto=f.Decrypt(TextoEncriptado)
           valores=SplitMe(Texto,"\|")
           txtServidor.Text=valores.Get(0)
           txtPort.Text=valores.Get(1)
           txtUser.Text=valores.Get(2)
           txtPassword.Text=valores.Get(3)
        End If
    End If

the File have 4 fields, not 3.. I don't understand..

I will search more
 
Upvote 0

Stephanie lie

Member
Licensed User
java.lang.IndexOutOfBoundsException: Indeks: 3, Ukuran: 3

 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…