How to get MMS id Android Application
Asked Answered
M

1

5

can anyone help me out to find MMS id, i using this code to get MMS text but i don't know the MMS id (mmsId) so i stopped !!

I'll be thankful for your help

Samila

Metalinguistic answered 8/4, 2012 at 18:26 Comment(1)
i am also having similar issue,let me know once you get solutionColchicine
U
1
Uri mmsInboxUri = Uri.parse("content://mms");               
Cursor mmsInboxCursor = getContentResolver().query(mmsInboxUri ,new String[]     
    {"_id","msg_box","ct_t","date"}, "msg_box=1 or msg_box=2", null, null);
int count = mmsInboxCursor.getCount(); 
if(mmsInboxCursor != null){

    try{

         if (mmsInboxCursor.moveToFirst())
         {                  
            do{

                System.out.println("<====MONITORING MESSAGES====>");                                
                int id = mmsInboxCursor.getString(0); 
              }while(mmsInboxCursor.moveToNext());
        }
    }catch (Exception e) {

        System.out.println("MMSMonitor :: startMMSMonitoring Exception== "+ e.getMessage());
    }
}
Unguentum answered 16/3, 2013 at 5:38 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.