0

I have a small app that calls the intent of image_capture from android, takes and then deletes it from the gallery.

Well, the picture is not deleted, well, not completely, the best result that I get it's this: enter image description here

My code is simple, based on what I found around internet:

success = new File(imageUrl).delete();
//deleteFile(imageUrl);
if(success)
    sendBroadcast(new Intent(Intent.ACTION_MEDIA_MOUNTED, Uri.parse("file://" + Environment.getExternalStorageDirectory())));

What can I do to solve this problem?

Blackout
  • 157
  • 1
  • 3
  • 14
  • The image is still registered with the media library see http://stackoverflow.com/questions/8379690/androids-media-scanner-how-do-i-remove-files – weston Jul 13 '16 at 21:59
  • the selected solution there still gets the same: corrupted file. – Blackout Jul 13 '16 at 22:20
  • Try the other answers maybe. – weston Jul 13 '16 at 22:28
  • sure... I'm still looking for the solution. I tried also this link: http://stackoverflow.com/questions/3300137/how-can-i-refresh-mediastore-on-android but, still the same! – Blackout Jul 13 '16 at 22:29

0 Answers0