且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

发送短信的android

更新时间:2023-01-06 13:45:59

您可以使用下面的code:

You can use the following code:

startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse("sms:"
                        + phoneNumber)));

请确保您设置 phoneNumber的来,你要发送消息的电话号码

Make sure you set phoneNumber to the phone number that you want to send the message to