Alexander Braunreuther
Alexander Braunreuther

Reputation: 404

Android FileNotFoundException even if file is available and permission set

I'm saving an Image taken by camera to the external storage. Later on I want to upload the image to our servers.

There I try to recreate the file from path but always a FileNotFoundException appears.

File file = new File("file:/storage/emulated/0/Pictures/Instantley/IMG_20160523_170354803382833.jpg");

I already checked:

Upvotes: 1

Views: 82

Answers (1)

joschi70
joschi70

Reputation: 56

Try it without the file: prefix:

file = new File("/storage/emulated/0/Pictures/Instantley/IMG_20160523_170354803382833.jpg");

Upvotes: 3

Related Questions