Android 10 Unable to open '/storage/emulated/0/: Permission denied

Android 10 Unable to open '/storage/emulated/0/: Permission denied

When reading the SD card data in Android10, it reported such an error. At first, I was confused, and the permission was also added. Why did it report no permission. Here is the new mechanism of Android, each application can only access the following path:

/storage/emulated/0/Android/data/<包名>/files

The files under the name of your own SD storage package cannot be accessed under other paths. Putting all access data under this path will not report an error.

For details, you can search: Android 10 Adaptation Essentials, Scope Storage This article

Guess you like

Origin blog.csdn.net/yanwenyuan0304/article/details/106104159