Android Question debug mode error with android 6.0.1

analizer3816

Member
Licensed User
Longtime User
I testes app with galaxy note 5 on android 5.1,it works fine both debug and release mode.
when I updated to android 6.0.1 and tested app with same environment again,
"fontawesome-webfont-4.3.0.ttf" file is in Project folder/Files/fonts/
only debug mode shows error
help me please

Code: Copy
PackageAdded: package:thaithamsoft.xxx
Copying updated assets files (11)
java.lang.RuntimeException: Unable to create service thaithamsoft.xxx.starter: java.lang.RuntimeException: java.io.FileNotFoundException: /storage/emulated/0/Android/data/thaithamsoft.xxx/files/virtual_assets/fonts/fontawesome-webfont-4.3.0.ttf: open failed: ENOENT (No such file or directory)
    at android.app.ActivityThread.handleCreateService(ActivityThread.java:3818)
    at android.app.ActivityThread.access$2100(ActivityThread.java:222)
    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1883)
    at android.os.Handler.dispatchMessage(Handler.java:102)
    at android.os.Looper.loop(Looper.java:158)
    at android.app.ActivityThread.main(ActivityThread.java:7229)
    at java.lang.reflect.Method.invoke(Native Method)
    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
Caused by: java.lang.RuntimeException: java.io.FileNotFoundException: /storage/emulated/0/Android/data/thaithamsoft.xxx/files/virtual_assets/fonts/fontawesome-webfont-4.3.0.ttf: open failed: ENOENT (No such file or directory)
    at anywheresoftware.b4a.shell.Shell.virtualAssets(Shell.java:167)
    at anywheresoftware.b4a.shell.Shell.start(Shell.java:99)
    at anywheresoftware.b4a.ShellBA.raiseEvent2(ShellBA.java:88)
    at thaithamsoft.phothithamGPA.starter.onCreate(starter.java:32)
    at android.app.ActivityThread.handleCreateService(ActivityThread.java:3808)
    ... 8 more
Caused by: java.io.FileNotFoundException: /storage/emulated/0/Android/data/thaithamsoft.xxx/files/virtual_assets/fonts/fontawesome-webfont-4.3.0.ttf: open failed: ENOENT (No such file or directory)
    at libcore.io.IoBridge.open(IoBridge.java:452)
    at java.io.FileOutputStream.<init>(FileOutputStream.java:87)
    at anywheresoftware.b4a.objects.streams.File.OpenOutput(File.java:370)
    at anywheresoftware.b4a.shell.Shell.virtualAssets(Shell.java:154)
    ... 12 more
Caused by: android.system.ErrnoException: open failed: ENOENT (No such file or directory)
    at libcore.io.Posix.open(Native Method)
    at libcore.io.BlockGuardOs.open(BlockGuardOs.java:186)
    at libcore.io.IoBridge.open(IoBridge.java:438)
    ... 15 more
 
<uses-sdk android:minSdkVersion="14" android:targetSdkVersion="23"/>

and configure path:
C:\Program Files (x86)\Android\android-sdk\platforms\android-23\android.jar
 
Upvote 0
When you set it to 23 you must implement the new runtime permissions system. The debugger currently doesn't implement it (it will be supported in the near future).

When you set it to 22 you are telling Android to use the "old" permissions system and your app will work on all devices.
 
Upvote 0
thank you very much, now it works fine.
I changed targetSdkVersion="22" and configure path:
C:\Program Files (x86)\Android\android-sdk\platforms\android-23\android.jar
 
Upvote 0

Similar Threads

Back
Top