Some basics on Android storage system

Thanks a lot for this Guide image but I have some confusions.

  1. This Guide is working for all Android versions ?
  2. If I want to make non private external storage for ex.(storage/emulated/0/Myfolder) you write that it must be approved by Google what does it mean?
  3. What does this directory called ?(Android/media/com.whatsapp) And can we make this type of directory also like whatsapp make (if yes than which permission we need)
  4. Want more information about Non private external storage.
    @bodymindpower I want your help

@bodymindpower
I am using a image picker in my app that takes image from gallery and copy to ASD.
I am aware about SAF and its extension
Problem which i am facing is that i need to give separate tree access if i want to use image from DCIM and if i need from whatsApp folder.
As such in the extension i cannot give access to full storage in one access.
I have asked the question with extension developer, he told that i need to go ahead with multiple access
Is there any other way out for my problem?

the permission MANAGE_EXTERNAL_STORAGE must be approved by Google, see also Manage all files on a storage device  |  Android Developers

good question… I do not know… let me suggest to read the Android documentation… here is a start App data and files  |  Android Developers see also permissions - Android 11 Access other apps Data in Android/media - Stack Overflow
let us know, what you find out…

Taifun

Approve by Google? How to take approval is this means that google review our app and then if it’s approved.
What if I make app not for playstore??

Unfortunately I didn’t understand from android documentation that’s why I asked here

concerning the approval see also this link Use of All files access (MANAGE_EXTERNAL_STORAGE) permission - Play Console Help

then you can use that permission without approval from Google
however you have to add it into the manifest

Taifun

It is called: /Android/media/ (There is no special name for it.)

Yes, but you cannot write to it:

The same with a file extension from @Taifun or @vknow360.

So as I said you need SAF for this.

1 Like

Where is the problem to copy a media file from e.g. /Pictures or /DCIM to the ASD?
Why should you use SAF for that?

Can we read these directory ?

Is SAF able to do this ?

Important thing is how others apps are able to do these all commands like making directory read and write them

Just a last question :interrobang: . Can we make these type of independent directories of our app like this

No, not without special permission.
Btw, what are “independent directories”?

But, as I said (now for the third time), what about trying out something yourself?

1 Like

the question remains, how Whatsapp is able to read and write in directory /Android/media as far as I know without requiring additional permission from the user (at least I do not remember to have given additional permission to Whatsapp)…

Taifun

1 Like

Using MediaStore?

It is no problem to read from this path (folder) on any Android version.
But with targetSdkVersion = 30 it is no longer possible to write / save / copy to this folder on devices with Android > 10.

I have never used or installed WhatsApp and it will stay that way. So I can’t say anything about whether it will still save files to this folder on Android 11.
But MANAGE_EXTERNAL_STORAGE is not declared in the WhatsApp Manifest.

2 Likes

But if the image picker is selecting the image from whatsapp folder
for that we require SAF to copy it to ASD.

I never said it required SAF for this. Please read carefully.

1 Like

2 posts were split to a new topic: Help needed for viewing subtitle files from phone

Very good :heart::blush:

6 posts were split to a new topic: How to find package name folder org.telegram.messenger?