zoukankan      html  css  js  c++  java
  • 收发短信API

    void android.telephony.SmsManager.sendTextMessage(String destinationAddress, String scAddress, String text, PendingIntent sentIntent, PendingIntent deliveryIntent)

    Send a text based SMS.

    Parameters:

    destinationAddress the address to send the message to

    scAddress is the service center address or null to use the current default SMSC

    text the body of the message to send

    sentIntent if not NULL this PendingIntent is broadcast when the message is successfully sent, or failed. The result code will be Activity.RESULT_OK for success, or one of these errors: RESULT_ERROR_GENERIC_FAILURE RESULT_ERROR_RADIO_OFF RESULT_ERROR_NULL_PDU For RESULT_ERROR_GENERIC_FAILURE

    the sentIntent may include the extra "errorCode" containing a radio technology specific value, generally only useful for troubleshooting. The per-application based SMS control checks sentIntent. If sentIntent is NULL the caller will be checked against all unknown applications, which cause smaller number of SMS to be sent in checking period.

    deliveryIntent if not NULL this PendingIntent is broadcast when the message is delivered 传递 to the recipient 接收者. The raw pdu of the status report is in the extended data ("pdu").

    Throws:

    IllegalArgumentException - if destinationAddress or text are empty


  • 相关阅读:
    中文简体汉字
    文件下载
    javaBean
    servlet和JSP笔记(EL表达式、javabean、jsp九大内置对象等)
    Http请求和响应
    Eclipse快捷键(可更新)
    反射笔记①
    泛型, 枚举,单例模式
    Ubuntu 14.04 安装 A卡HD7750 官方闭源 显卡驱动
    C语言--二维数组,字符串数组,多维数组
  • 原文地址:https://www.cnblogs.com/fengzhblog/p/2792439.html
Copyright © 2011-2022 走看看