Home > Blockchain >  Android 11 doesn't create app directory on internal storage
Android 11 doesn't create app directory on internal storage

Time:06-21

I installed my app on Android 11. But there are no folder under setting--> Storage--> Files--> Android--> data.

My app cannot create its own app-specific directory.

Is there any one have some suggestions?

Best, QZ

CodePudding user response:

On Android 11, apps cannot read or write to other apps' directories inside the Android/data folder.

Check the reference: Official Android Guide

CodePudding user response:

In fact Your app has created app-specific dir but you can't see that folder in your file manager. Because some changed applied in android 11 device that User can't open Android/Data Folder You can user some file manager like (X-plore File Manager) to open Android/Data folder

CodePudding user response:

You can directly create data in your own application directory, but you cannot create folders directly in other directories, because of security issues, it is not allowed to obtain the absolute path of the data.

App-specific directory on external storage

Starting in Android 11, apps cannot create their own app-specific directory on external storage. To access the directory that the system provides for your app, call getExternalFilesDirs().

Other reference: android-11-scoped-storage-permissions

  • Related