Can't save captured image with Android 4.2.2 <p>In my app I need to capture image with the standard camera app. So, what I did is:</p> <pre><code>public void TakePhotoProofs() { // fetching the root directory root = Environment.getExternalStorageDirectory().toString() + "/MyAppStoredImages"; // Creating folders for Image imageFolderPath = root + "/captured_images"; File imagesFolder = new File(imageFolderPath); if (!imagesFolder.exists()) { imagesFolder.mkdirs(); } // Generating file name by current date Time today = new Time(Time.getCurrentTimezone()); today.setToNow(); imageName = today.format("%Y-%m-%d-%H-%M-%S") + ".png"; // Creating image here File image = new File(imageFolderPath, imageName); fileUri = Uri.fromFile(image); imvPhotoFrame.setTag(imageFolderPath + File.separator + imageName); Intent takePictureIntent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE); takePictureIntent.putExtra(MediaStore.EXTRA_OUTPUT, fileUri); startActivityForResult(takePictureIntent, CAMERA_IMAGE_REQUEST); } </code></pre> <p><strong>In this code snipped I faced with the following issue:</strong></p> <ol> <li>When the Intent is started I have the standard camera app opened</li> <li>Then I press the button to capture image</li> <li>In this step I expected to see the Activity with captured image and two buttons "Save" and "Cancel", <strong>but instead I see black screen and then the Activity from step (1)</strong></li> <li>In the bottom of this Activity there should be couple of frames with thumbnails of previously and currently captured images, but there is only one empty frame.</li> <li>When I return to my app in the method <code>onActivityResult()</code> the variable <strong>fileUri</strong> should contain path to captured image that in previous step should be saved in my folder <strong>/MyAppStoredImages/captured_images</strong></li> <li>The sampling image I place in the special ImageView. But it is empty and when I click there to open fullsize image it says <strong>"Cannot find an element"</strong></li> </ol> <p><strong>Note: if I run the standard camera app separately, the bottom frames (from step (4)) are not empty.</strong></p> <p>This behaviour has arisen after I updated my firmware from Android 4.1.2 Jelly Bean to Android 4.2.2 Jelly Bean. With Android 4.1.2 Jelly Bean all images were being captured properly.</p> <p>Did someone have the same issue? What should I do in this case?</p> <p><strong>UPDATE:</strong> Using the proposition given by @Mohit in <a href="http://stackoverflow.com/questions/16348757/mediastore-extra-output-renders-data-null-other-way-to-save-photos">this post</a>, I added the following line after putting EXTRA_OUTPUT:</p> <pre><code>takePictureIntent.putExtra("return-data", true); </code></pre> <p>Now, it works properly with third-party camera app (I tested with <a href="https://play.google.com/store/apps/details?id=com.magix.camera_mx" rel="nofollow">CameraMX</a>). But still I can't use my default camera app (via invocations described above, I can't save captured image. But separately this default app works properly too).</p> <p>So, if you encountered the same problem, please, refer me to the correct way.</p> <p>Just in case, this problem arose on the Samsung Galaxy Grand Duos i9082 and its default camera app after upgrading to Android 4.2.2)</p>