How to Share Text to Social Media

The code used:

Intent sendIntent = new Intent();

sendIntent.setAction(Intent.ACTION_SEND);

sendIntent.putExtra(Intent.EXTRA_TEXT, _text);

sendIntent.setType("text/plain");

Intent shareIntent = Intent.createChooser(sendIntent, null);

startActivity(shareIntent);

Comments

Popular posts from this blog

How to Create Material Ripple Effect in Sketchware

How to Create Custom Notifications with Listeners

How to create Custom Dialog in Sketchware