Extension is using full path and I've workaround so on many Android versions (for old one especially with permissions), that works — even if technically it's ASD.
When you use the extension to create a PDF or image, it needs to save that file somewhere on your phone or tablet. Instead of saving it in a shared place (like the Downloads folder), it saves it in a private folder that only the app can use. This folder is called the app-specific external storage directory.
Upto android ver.9 No permission is needed, and it’s the folder >>>>> /storage/emulated/0/Android/data/<app_name>/files/
Android 10 started changing storage rules (called "scoped storage"), but the app’s private folder used without permission.
Android 11 has storage rules strict for accessing other app's files but own files can be read/write without any permission apps can easily write to shared places (like Downloads, Pictures, Music etc. other similar shared storage) without asking the user + the app’s private folder is still free to use**.
The extension always saves files in a folder that belongs only to your app, like a private locker.
In simple words Simply drop the sharing component it will include Read_storgae permission, in blocks ask for Write_External storage permission, read and write storage permission is required for old android versions which need these permission, other things extension will mange by itself.
That statement was wrong of mine regarding shared storage for Android 11+ @Anke
Import the AIA file build APK and test on real device android version 8/9 (saying 8/9 because I tested on android version 9 without permissions) 1. with sharing component i.e.only with read permission but without Write permission AND 2.without sharing component i.e. without read & write permission.
On Android 11 and later, apps are generally not allowed to write to shared folders (or other external storage directories) without obtaining explicit permission or user interaction. This is due to the scoped storage model, which was introduced to enhance user privacy and security by limiting direct access to shared storage.
Key Points:
Scoped Storage: Android 11 enforces stricter access rules, meaning apps can only access their own app-specific directories or use designated APIs (like MediaStore) for shared media files.
User Consent Required: Writing to other shared folders typically requires the user to grant access through mechanisms such as the Storage Access Framework, where the user explicitly selects the folder or file.
No Silent Access: Without explicit permission or user interaction, your app cannot write to arbitrary shared folders. Attempting to do so will result in a security exception.
Thus, without explicit permissions or user interaction, you cannot write to shared folders on Android 11+.
I always test my extensions personally before publishing here. I provide AIA including what is needed for the extension (for eg. When I tested the extension using sharing component in MIT built apk in real device ver.9 that did not work coz was missing write_ext_storage on the other hand when used on kodular with sharing component that worked coz sharing component of kodular includes both read & write permissions. The most important thing for me is, when someone purchase my extension he/she will not face any difficulty for all android versions, and they must not face any rejection/suspension from play store.
Then prove with Android's official document reference where they mention this "No, you can of course write to one of the shared folders on Android 11+ without permission or user interaction."
You too prove with Android's official document reference where they mention this "No, you can of course write to one of the shared folders on Android 11+ without permission or user interaction."
We are doing this already since a few years
Just write a small test project and use the file component to store a file in /Download
No permission needed for newer devices