Android Question open failed: EACCES (Permission denied)

iCAB

Well-Known Member
Licensed User
Longtime User
Hi All,

I am using JHSBarCodes Library, all was ok until I changed the target sdk from 28 to 29

B4X:
<uses-sdk android:minSdkVersion="9" android:targetSdkVersion="29"/>

Android jar
B4X:
C:\android_sdk_2\platforms\android-30\android.jar

At startup the app is requesting external storage permission
B4X:
PERMISSION_WRITE_EXTERNAL_STORAGE

The error I am getting is
B4X:
(ErrnoException) android.system.ErrnoException: open failed: EACCES (Permission denied)

Any ideas?
 
Any ideas?
Did you add this line to the manifest:
Code:
SetApplicationAttribute(android:requestLegacyExternalStorage, true)
See reason here why:
 
Upvote 1
He has posted the library source here and it is written in B4A.
If you want to keep using you could change where each code module saves it result to a different folder like RunTimePermissions.GetSafeDirDefaultExternal. That code is at the end of each module.
 
Upvote 0
Back
Top