This is my code to access abc.jpg file in Music folder.
String m=Environment.getStorageDirectory().getPath();
inputStream=cr.openInputStream(Uri.parse("file:"+Environment.getExternalStorageDirectory().getPath()+"/Music/abc.jpg"));
when i try to run this code it gives error.
File Not Found
We have to add
android:requestLegacyExternalStorage="true"
In Android Mainfest File.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.