TutorialsAndroid/FilePicker

Unable to see storage in Android 10

alifhasnain opened this issue ยท 13 comments

I don't see any internal or external storage location even though I have WRITE_EXTERNAL_STORAGE permission when I open file picker dialog in Android Q.

I have the same issue. Any updates?

No. I have not found any way to fix this and library creator is not replying.

No. I have not found any way to fix this and library creator is not replying.

sorry for the late reply. we will be updating this library in 2 days to support android 10

I have the same issue. Any updates?

sorry for late reply we will be updating this library in 2 days

I don't see any internal or external storage location even though I have WRITE_EXTERNAL_STORAGE permission when I open file picker dialog in Android Q.

May be now it will work on android 10 i have updated this library

I have the same issue. Any updates?

May be now it will work on android 10 i have updated this library

Download the latest verison of library v5.0.19

The problem was requestLegacyExternalStorage was not set to true in the manifest file. Because of scoped external storage by default it is set to false in Android 10 or higher. Adding this line in the AndroidManifest.xml solved my problem.

<manifest ... >
  <!-- This attribute is "false" by default on apps targeting
       Android 10 or higher. -->
  <application 
       android:requestLegacyExternalStorage="true" ........ >
    ......
  </application>
</manifest>

The problem was requestLegacyExternalStorage was not set to true in the manifest file. Because of scoped external storage by default it is set to false in Android 10 or higher. Adding this line in the AndroidManifest.xml solved my problem.

<manifest ... >
  <!-- This attribute is "false" by default on apps targeting
       Android 10 or higher. -->
  <application 
       android:requestLegacyExternalStorage="true" ........ >
    ......
  </application>
</manifest>

Thank you to solve this problem @alifhasnain

I am running the sample app on my Android 10 Emulator with an external sd card. The external sd card is not showing unfortunately. I only see 2 dirs under /mnt, asec and obb. Anyone knows how to fix this?

Edit: Ah.. Im running SDK 30, thats Android 10+. I guess that's not supported yet.

I only see 2 dirs under /mnt, asec and obb. Anyone knows how to fix this?

Any news on this? Android 11 not supported?

I am running the sample app on my Android 10 Emulator with an external sd card. The external sd card is not showing unfortunately. I only see 2 dirs under /mnt, asec and obb. Anyone knows how to fix this?

Edit: Ah.. Im running SDK 30, thats Android 10+. I guess that's not supported yet.

How to fixed it???

Ok i will check this on this issue. I will update it soon in few days