Thank you very much ,I will try this。

 

  _____  

From: [email protected]
[mailto:[email protected]] On Behalf Of eaindra nilar
Sent: Thursday, September 10, 2009 6:59 PM
To: [email protected]
Subject: [android-developers] Re: Is there any method to read sms and gmail?

 

Hello,

You can read sms this way
public class SmsApp extends Activity {
    /** Called when the activity is first created. */
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);
        String strUri="content://sms/inbox";
        Uri urisms=Uri.parse(strUri);
        //try{
        Cursor c=this.getContentResolver().query(urisms, null, null, null,
null);
        while(c.moveToNext())

-~----------~----~----~----~------~----~------~--~---

but you need permission ,u described  SMS_READ



--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to