Skip to content

Instantly share code, notes, and snippets.

@yaraki
Created June 12, 2023 09:41
Show Gist options
  • Save yaraki/5d512f0e08a72c0ddac2f34bf6a0256c to your computer and use it in GitHub Desktop.
Save yaraki/5d512f0e08a72c0ddac2f34bf6a0256c to your computer and use it in GitHub Desktop.
val sendIntent = Intent(Intent.ACTION_SEND)
.putExtra(Intent.EXTRA_TEXT, "This is my text to send.")
.setType("text/plain")
val shareIntent = Intent.createChooser(sendIntent, null)
context.startActivity(shareIntent)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment