Open File Error 2102

Trying to make app read text file after pick choice, permission allow, directory checked, file found but can't open file

Android 7.0



Always show your blocks and name the Android version, see here:

Sorry for missing info Code and Android version added

Read my posts!

If a non-media file is NOT created by the app itself, it cannot be read / accessed from one of the Shared folders /Download or /Documents or any other arbitrary folder of the external storage (outside the ASD) on Android 11+. You must use SAF.

Where does the text file come from?

1 Like

I do read first 2 post before create this topic.

This text file is download from my PC and put into /Download

Then ...

on Android 11+ to access it.

But even with SAF you cannot access files in the Shared folder /Download, but in /Documents or any another folder - exept the root directory of the external storage.

Suggestion:
Put the text file in assets, then copy it to /Download and read it from there. Or upload it to Google Drive, then download it to the ASD and read it from there.