**If i share image one time in gmail and again come back and do some 
changes and again if i share then only previous image was displaying :( 
that was the issue with 4.1.1 when i run same problem in 4.2.2 it works 
perfectly :( :( :(**

Hi i what to share image using Intent for that i have used below code


       public void otherBtn(View v) {
FileOutputStream out = null;
try {
if (bitmap != null) {
bitmap.recycle();
bitmap = null;
}
Intent sharingIntent = new Intent(Intent.ACTION_SEND);
File sdcard = Environment.getExternalStorageDirectory();
File f = new File(sdcard, "temp.jpg");
if (f.isFile()) {
f.delete();
}
out = new FileOutputStream(f);
captureRelativeLayout.setDrawingCacheEnabled(true);
bitmap = captureRelativeLayout.getDrawingCache(true).copy(
Config.ARGB_8888, false);
bitmap.compress(Bitmap.CompressFormat.JPEG, 90, out);

sharingIntent.putExtra(Intent.EXTRA_STREAM, Uri.fromFile(f)); // imageUri
sharingIntent.setType("image/jpg");
startActivity(sharingIntent);
} catch (Exception e) {
e.printStackTrace();
} finally {
if (out != null) {
try {
out.flush();
out.close();
} catch (Exception e) {
// TODO Auto-generated catch block
e.printStackTrace();
}

}
}
}



for example when i share below image with above code

<https://lh4.googleusercontent.com/-3A1l0CJnE5Y/UxBl4tEBFWI/AAAAAAAALYk/yOX8h4O3tH0/s1600/Qwydv%5B1%5D.png>
  


the image which i have previously shared will shown but not above updated 
image is showing :(

<http://i.stack.imgur.com/3dM89.png>




![enter image description here][2]

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Android Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to