file.exists() returns false for existing file in android

后端 未结 2 1782
余生分开走
余生分开走 2021-01-24 23:42

In my app user can select image from sdcard and set as profile picture. Everything is working fine but when user selects image from whatsapp folder from sdcard image can not dec

2条回答
  •  日久生厌
    2021-01-25 00:17

    If your ImageFile.exists() method is giving false in android, but it exists in memory, then you definitely have not given Write-external-storage Permission in the Manifest file of Your Project. Add this Permission in the Manifest of Your Project:

    
    

提交回复
热议问题