case R.id.action_share: {
Toast.makeText(this, getString(R.string.share_app_with), Toast.LENGTH_SHORT).show();
try {
Intent i = new Intent(Intent.ACTION_SEND);
i.setType("text/plain");
i.putExtra(Intent.EXTRA_SUBJECT, "Easy Repeater Text");
String sAux = "\nLet me recommend you this amazing application\n\n";
sAux = sAux + "http://play.google.com/store/apps/details?id=com.uday.textrepeatereasy\n\n\n";
i.putExtra(Intent.EXTRA_TEXT, sAux);
startActivity(Intent.createChooser(i, getString(R.string.share_app_with)));
} catch (Exception e) {
//e.toString();
}
}
This will explains how to share your published app in Google Play Store through intent.
Be the first to comment
You can use [html][/html], [css][/css], [php][/php] and more to embed the code. Urls are automatically hyperlinked. Line breaks and paragraphs are automatically generated.