Broadcast Receiver for Sent SMS

前端 未结 2 505
無奈伤痛
無奈伤痛 2021-01-03 12:39

Is there a Broadcast Receiver in android to listen to the SMS sent event?

In my application I want to count the number of SMS sent every predefined time interval. If

相关标签:
2条回答
  • 2021-01-03 12:54

    Check this link....i think its not complete solution but you have some idea how to implement...

    http://www.anddev.org/other-coding-problems-f5/sms-mms-contentobserver-and-service-t12938.html

    you can implement content://sms/sent observer se.. so if any changes in this then you can get event so u can count or get action sent sms or mms.......

    0 讨论(0)
  • 2021-01-03 13:01

    You can edit your own sms with SmsManager api from google and be notified by a PendingIntent:

    SmsManager smsManager = SmsManager.getDefault();
    smsManager.sendTextMessage (String destinationAddress, String scAddress, String text, PendingIntent sentIntent, PendingIntent deliveryIntent)
    

    You can be notified of the delivery with the parameter: PendingIntent sentIntent

    But SmsManager is now deprecated :(

    0 讨论(0)
提交回复
热议问题