Reputation: 139
In my case, the file is placed at the location: Storage/Movie/app_name/db/player.json
So, I want to read player.json file data in my app.
For Android 9 and below, I used READ_EXTERNAL_STORAGE and WRITE_EXTERNAL_STORAGE. For Android 10, I used MANAGE_EXTERNAL_STORAGE. I need a proper solution, including any alternative for Android 10 as well. Now, I need a solution for Android 11 and above.
I think MANAGE_EXTERNAL_STORAGE works with Android 11 and 12, but we need a solution for Android 13 and above.
Tried: Using File("Storage/Movie/app_name/db/player.json"), but this method throws an exception file open failed:EACCES(Permission denied).
Note: Remember that I am asking for a solution for Android TV OS.
Upvotes: 1
Views: 33