scsjc Well-Known Member Licensed User Longtime User Jul 6, 2018 #1 I use the appcompat.ACActionBar.setUpIndicatorBitmap and sometimes receive NullPointerException from customers Code: Copy java.lang.NullPointerException: at de.amberhome.objects.appcompat.ACActionBar.setUpIndicatorBitmap (ACActionBar.java:112) at com.oficinadirecta.main._cargamenu (main.java:3346) at java.lang.reflect.Method.invoke (Native Method) at java.lang.reflect.Method.invoke (Method.java:372) at anywheresoftware.b4a.BA.raiseEvent2 (BA.java:186) at anywheresoftware.b4a.keywords.Common$11$1.run (Common.java:1139) at anywheresoftware.b4a.BA.setActivityPaused (BA.java:432) at com.oficinadirecta.main.afterFirstLayout (main.java:108) at com.oficinadirecta.main.access$000 (main.java:17) at com.oficinadirecta.main$WaitForLayout.run (main.java:82) at android.os.Handler.handleCallback (Handler.java:815) at android.os.Handler.dispatchMessage (Handler.java:104) at android.os.Looper.loop (Looper.java:194) at android.app.ActivityThread.main (ActivityThread.java:5931) at java.lang.reflect.Method.invoke (Native Method) at java.lang.reflect.Method.invoke (Method.java:372) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run (ZygoteInit.java:987) at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:782) The code i'm use is: Code: Copy ABHelper.UpIndicatorBitmap=LoadBitmapSample(File.DirAssets,"burguermenu.png",80dip,80dip)
I use the appcompat.ACActionBar.setUpIndicatorBitmap and sometimes receive NullPointerException from customers Code: Copy java.lang.NullPointerException: at de.amberhome.objects.appcompat.ACActionBar.setUpIndicatorBitmap (ACActionBar.java:112) at com.oficinadirecta.main._cargamenu (main.java:3346) at java.lang.reflect.Method.invoke (Native Method) at java.lang.reflect.Method.invoke (Method.java:372) at anywheresoftware.b4a.BA.raiseEvent2 (BA.java:186) at anywheresoftware.b4a.keywords.Common$11$1.run (Common.java:1139) at anywheresoftware.b4a.BA.setActivityPaused (BA.java:432) at com.oficinadirecta.main.afterFirstLayout (main.java:108) at com.oficinadirecta.main.access$000 (main.java:17) at com.oficinadirecta.main$WaitForLayout.run (main.java:82) at android.os.Handler.handleCallback (Handler.java:815) at android.os.Handler.dispatchMessage (Handler.java:104) at android.os.Looper.loop (Looper.java:194) at android.app.ActivityThread.main (ActivityThread.java:5931) at java.lang.reflect.Method.invoke (Native Method) at java.lang.reflect.Method.invoke (Method.java:372) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run (ZygoteInit.java:987) at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:782) The code i'm use is: Code: Copy ABHelper.UpIndicatorBitmap=LoadBitmapSample(File.DirAssets,"burguermenu.png",80dip,80dip)
Erel B4X founder Staff member Licensed User Longtime User Jul 8, 2018 #2 Check this example: https://www.b4x.com/android/forum/threads/appcompat-with-toolbar-minimal-example.79896/ Upvote 0
Check this example: https://www.b4x.com/android/forum/threads/appcompat-with-toolbar-minimal-example.79896/
scsjc Well-Known Member Licensed User Longtime User Jul 8, 2018 #3 I think I have found the error ... the code to a toolbar.menu.clear and in time of execution it would go through this line Upvote 0
I think I have found the error ... the code to a toolbar.menu.clear and in time of execution it would go through this line
D Don Oso Active Member Licensed User Longtime User Jul 21, 2018 #4 its a check box in the designer -> https://www.b4x.com/android/forum/threads/acactionbar-is-not-initialized-why.89805/#content Upvote 0
its a check box in the designer -> https://www.b4x.com/android/forum/threads/acactionbar-is-not-initialized-why.89805/#content