1.调用系统发短信界面:
Intent intent = new Intent(); intent.setAction(Intent.ACTION_SENDTO); intent.setData(Uri.parse("smsto:xxxxxxxxx"));//设置收件人号码 intent.putExtra("sms_body", "reset");//设置短信内容 startActivity(intent);
2.调用系统的分享功能:
String content = "xxxxxxxxxxx"; Intent intentShare=new Intent(Intent.ACTION_SEND); intentShare.setType("image/*"); intentShare.putExtra(Intent.EXTRA_SUBJECT, "分享"); intentShare.putExtra(Intent.EXTRA_TEXT, content); intentShare.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK); startActivity(Intent.createChooser(intentShare, "分享"));