Android: NPE happens when getting picture from camera?

Are you sure that image crop mode forcing intent. PutExtra("return-data", true) works correctly for the device you use. Correct me if I am wrong, but it is not safe and not well documented approach.

Here you can find example of working code without cropping UPDATE: Issue you are facing with has long history, also at SO: stackoverflow.com/questions/3904685/unab... Issue I experienced was using crop immediatelly after image was taken by the camera. Also, it is not compatible through different Android versions, so if you get it working for 1. 5 maybe it will not work for 2.3. Definitely something is wrong, as may be concluded from the Android Developer Group posts: groups.google.com/group/android-develope... groups.google.com/group/android-develope... groups.google.com/group/android-develope....

Are you sure that image crop mode forcing intent. PutExtra("return-data", true); works correctly for the device you use. Correct me if I am wrong, but it is not safe and not well documented approach.

Here you can find example of working code without cropping. UPDATE: Issue you are facing with has long history, also at SO: stackoverflow.com/questions/3904685/unab... Issue I experienced was using crop immediatelly after image was taken by the camera. Also, it is not compatible through different Android versions, so if you get it working for 1.

5 maybe it will not work for 2.3.Definitely something is wrong, as may be concluded from the Android Developer Group posts: groups.google.com/group/android-develope... groups.google.com/group/android-develope... groups.google.com/group/android-develope....

Thanks. I tried your codes on the simulators. It is working correctly.

Waiting feed-backs from DroidX. – user423715 Nov 25 '10 at 3:20 I am also interested to hear how does it work. – Zelimir Nov 25 '10 at 6:53 Tried described approach with cropping, and it definitely does not work correctly for the images taken directly from the camera (issue observed on Nexus One).

Cropping works fine for the pictures taken from image Gallery. So, definitely something is tricky (it is not null) with the URI of the image just taken from the camera. – Zelimir Dec 5 '10 at 12:56.

I have a problem on my Android app. I'm using MediaStore. ACTION_IMAGE_CAPTURE intent to take picture from camera.

It worked all most of devices but I got the following crash errors on DroidX device from android market. I think imageCaptureUri CANNOT be null in this case. So it is not the cause.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions