How to use SMS content provider? Where are the docs?

In addition to those u can see the list of fields in sms content provider by using following code:

private void displaySmsLog() {
    Uri allMessages = Uri.parse("content://sms/");
     //Cursor cursor = managedQuery(allMessages, null, null, null, null); Both are same
    Cursor cursor = this.getContentResolver().query(allMessages, null,
            null, null, null);

    while (cursor.moveToNext()) {
        for (int i = 0; i < cursor.getColumnCount(); i++) {
            Log.d(cursor.getColumnName(i) + "", cursor.getString(i) + "");
        }
        Log.d("One row finished",
                "**************************************************");
    }

}

Leave a Comment