Some questions about the Android intercept SMS

Source: Internet
Author: User

Recently toss android4.4 SMS blocker issue, ask to receive text messages on the app when pop-up hints and display the features.

Then we found two ways to use Broadcastreceiver and ContentProvider, and then the question came:

When I use ContentProvider and broadcast at the same time to deal with the discovery: if the use of ContentProvider text message processing (marked as read or deleted), Then the message will not be received in the Broadcastreceiver (android4.4 or later).

But if I do not deal with the time, look at log log, obviously is broadcastreceiver first executed.

Since Abortbroadcast is not available in the android4.4 or above version of SMS, I android4.4 the following version of the test to use Abortbroadcast in Broadcastreceiver, the result ContentProvider will not be received.

This is very confusing.

In addition, I also used the Vivo x3l mobile phone, this phone is the default with Rights management software, and in this mobile phone use of SMS broadcastreceiver when there is a wonderful place, That's him. Although the system is 4.3, I also opened the right to read text messages, I can not intercept broadcast, and later I use ContentProvider operation read and write text messages to allow the read and write and delete text messages and send and receive text messages, the results can be received this broadcast, it is easy to think that the phone On your app must get all the rights to the text message you can receive SMS broadcast, and Xiaomi and Huawei mobile phones do not need, really ya ya egg pain ah.

Some questions about the Android intercept SMS

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.