Home > DeveloperSection > Interviews > How to share text using android share Intent ?

Posted on    June-11-2015 12:26 AM

 Android Android 
Ratings:
 1 Answer(s)
  379  View(s)
Rate this:

Mayank Tripathi
Mayank Tripathi

Total Post:807

Points:4035
Posted on    June-11-2015 12:26 AM

Share intent is an easy and convenient way of sharing content of your application with other apps.
Intent sendIntent = new Intent();
sendIntent.setAction(Intent.ACTION_SEND);
sendIntent.putExtra(Intent.EXTRA_TEXT, "This is my text to send.");
sendIntent.setType("text/plain");
startActivity(sendIntent);

Don't want to miss updates? Please click the below button!

Follow MindStick