I want to open the Android SMS application from my application and I don't want to set any contact as a recipient, How?
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
Uri uri = Uri.parse("smsto:");
Intent intent = new Intent(Intent.ACTION_SENDTO, uri);
intent.putExtra("sms_body", "Hello World!");
startActivity(intent);
note
this way doesn't need any permission in Manifest