Android Send Sms Pending Intent
Solution 1:
My question is when I get
RESULT_OK, how can I know the_idcolumn of the cursor adapter?
You can put a ContentObserver on the SMS Provider in order to receive a callback when the message gets written, and then query the Provider to get the message ID. I've an example of how to do that in my answer here. You would just need to change "thread_id" to "_id".
I can check for the
_idlater but is there a way to get it from thependingIntent?
Unfortunately, no. That Intent is not going to carry much information beyond the result code. It might have a few extras attached - e.g., the SIM slot number - but it won't have the ID assigned by the SMS ContentProvider.
I'm not getting any callback on the
deliveryIntentafter delivery.
That's not unusual. The delivery PendingIntent will only fire if confirmation is received from the service center, but not every wireless provider offers that functionality.
Post a Comment for "Android Send Sms Pending Intent"