Android sharing intent

The code snippet below will open up a dialog with app installed on the phone that accepts this ACTION_SEND intent. The use will be able to choose the app and send the information to that app.

Intent sharingIntent = new Intent(android.content.Intent.ACTION_SEND);
sharingIntent.setType("text/plain");
String content = "Put whatever information you would like to share through other apps.";
sharingIntent.putExtra(android.content.Intent.EXTRA_SUBJECT, "Subject");
sharingIntent.putExtra(android.content.Intent.EXTRA_TEXT, content);
startActivity(Intent.createChooser(sharingIntent, "Share via"));

Search within Codexpedia

Custom Search

Search the entire web

Custom Search