Trying to use Floating button. I followed this Thread: https://www.b4x.com/android/forum/threads/sd-floating-button-standout.80847/#content
The example runs fine.
When I add it to my program I get the following error:
Furthermore I have this error is from the release. If needed I can post the Error from Debug.
The example runs fine.
When I add it to my program I get the following error:
B4X:
java.lang.reflect.InvocationTargetException
at java.lang.reflect.Method.invoke(Native Method)
at anywheresoftware.b4j.object.JavaObject.RunMethod(JavaObject.java:131)
at b4a.example.standout._init_elements(standout.java:314)
at b4a.example.standout._service_start(standout.java:552)
at java.lang.reflect.Method.invoke(Native Method)
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:179)
at anywheresoftware.b4a.BA.raiseEvent(BA.java:163)
at b4a.example.standout.handleStart(standout.java:113)
at b4a.example.standout.onStartCommand(standout.java:81)
at android.app.ActivityThread.handleServiceArgs(ActivityThread.java:3738)
at android.app.ActivityThread.-wrap23(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1744)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:154)
at android.app.ActivityThread.main(ActivityThread.java:6780)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1496)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1386)
Caused by: android.view.WindowManager$BadTokenException: Unable to add window android.view.ViewRootImpl$W@20665ef -- permission denied for window type 2002
at android.view.ViewRootImpl.setView(ViewRootImpl.java:921)
at android.view.WindowManagerGlobal.addView(WindowManagerGlobal.java:342)
at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:97)
at b4a.example.standout$CustomImageView.sharedConstructing(standout.java:633)
at b4a.example.standout$CustomImageView.<init>(standout.java:604)
at b4a.example.standout.newInstance2(standout.java:771)
... 18 more
Furthermore I have this error is from the release. If needed I can post the Error from Debug.
Last edited: