Android Camera, does not return to onActivityResult and resets calling activity

0

What is surprising is that the documented way of making this shit work does not work.

http://developer.android.com/guide/topics/media/camera.html

Scroll to Image Capture Intent,

// photoIDFile is type File
intent.putExtra(MediaStore.EXTRA_OUTPUT, Uri.fromFile(photoIDFile)); // set the image file name

With this it just does not work. My Uri is correct, I have

file:///data/data/com.samagra.operatorapp/files/photo1441253398999.jpg

But this gets the camera to return.

intent.putExtra(MediaStore.EXTRA_OUTPUT, Uri.fromFile(photoIDFile).toString()); // set the image file name

Now the camera resets my activity and I loose my activity, it goes back SHAMELESSLY.

I had to read through the Camera documentation on android.developer.com and read Building a Camera App section. This worked well.

Advertisements