title: Captures the image from camera and load image into imageview of another activity
body: <p>i am getting a problem in fetching an image captured by camera into image view of another activity so please, find out the problem.....</p>
  
  <pre><code>      public void onClick(View v) {
  
                      Intent cameraIntent = new Intent(android.provider.MediaStore.ACTION_IMAGE_CAPTURE);  
  
                      startActivityForResult(cameraIntent, CAMERA_REQUEST);   
  </code></pre>
  
  <p>and the onActivityresult() is</p>
  
  <pre><code>protected void onActivityResult(int requestCode, int resultCode, Intent data,Uri mCapturedImageURI)
     {
  
         super.onActivityResult(requestCode, resultCode, data);
         if(requestCode==CAMERA_REQUEST&amp;&amp;resultCode==RESULT_OK)
           {
             String[] projection = { MediaStore.Images.Media.DATA}; 
  
             Cursor cursor = managedQuery(mCapturedImageURI, projection, null, null, null); 
             int column_index_data = cursor.getColumnIndexOrThrow(MediaStore.Images.Media.DATA); 
             cursor.moveToFirst(); 
             String picturepath = cursor.getString(column_index_data);
             Log.d("TAG", "getLastImageId::path " + picturepath);
             Intent   camintent= new Intent(MainActivity.this,GalleryActivity.class);
               camintent.putExtra("imagePath",picturepath );
               startActivity(camintent);
   }
  }
  </code></pre>
  
  <p>and my another(receiving) activity is........</p>
  
  <pre><code>      private void getData(){
  
          String ps=getIntent().getStringExtra("imagePath");
          img.setImageBitmap(BitmapFactory.decodeFile(ps));
       }
  </code></pre>