I am trying to write sms encryption tool. People using this tool will be able to chat without internet via sms and stay encrypted. The only thing I need is how to stop sms from particular number from getting into inbox folder, or delete sms notification and then delete sms from inbox.
I googled a lot, but https://stackoverflow.com/a/3875736/705297 this is not working. Broadcast is working, I see the log message that broadcastreceiver is launched, but it doesn't abort broadcast.
Also I found lots of messages that it is impossible. So is it possible and how I can do that? I am using android 2.1 and higher. Thanks
Code (just tries to cancel all sms for testing purposes): Broadcast receiver:
@Override
public void onReceive(Context context, Intent intent)
{
abortBroadcast(); }
Part of manifest:
<uses-permission android:name="android.permission.RECEIVE_SMS" />
<receiver android:name=".SMSReceiver">
<intent-filter android:priority="1000">
<action android:name="android.provider.Telephony.SMS_RECEIVED" />
</intent-filter>
</receiver>