I can't delete sms from inbox in kitkat version in android

≡放荡痞女 提交于 2019-12-11 03:08:07

问题


This is my delete code for an SMS:

if (context.getContentResolver().delete(Uri.parse("content://sms/inbox"), "date=? and body=?",
 new String[] { ctime, mess }) > 0) {
      Log.e("latest msg", "deleted");
}

回答1:


Unless your app is selected as the "Default SMS App" under "Settings->More..." then no, you can't.

http://developer.android.com/about/versions/kitkat.html#44-sms-provider



来源:https://stackoverflow.com/questions/21552458/i-cant-delete-sms-from-inbox-in-kitkat-version-in-android

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!