Last active
August 4, 2017 14:16
-
-
Save sakurabird/6923067 to your computer and use it in GitHub Desktop.
(android) LINEにIntentを送る
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Intent intent = new Intent(); | |
intent.setAction(Intent.ACTION_VIEW); | |
intent.setData(Uri.parse("line://msg/text/" + "LINEに送りたいテキストの内容"));// ブラウザ起動 | |
try { | |
startActivity(intent); | |
} catch (Exception e) { | |
Toast.makeText(getApplicationContext(), "LINEアプリがインストールされていません", Toast.LENGTH_LONG) | |
.show(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment