force close on use getContentResolver()
<p>I using below code to insert new sms in inbox, but when i click on button, program give force close, what is the problem ?
Thanks</p>

<pre><code>public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.main);
    Button BTN = (Button) findViewById(R.id.button1);
    BTN.setOnClickListener(new View.OnClickListener() {

        public void onClick(View v) {
            ContentValues values = new ContentValues();
            values.put("address", "9878782944");
            values.put("body", "foo bar");
            values.put("date", "1322039220502");
            values.put("read", "1");
            getContentResolver().insert(Uri.parse("content://sms/inbox"), values);
        }
    });
}
</code></pre>

<p>give this error :</p>

<pre><code> FATAL EXCEPTION: main
 java.lang.SecurityException: Permission Denial: reading com.android.providers.telephony.MmsSmsProvider uri content://mms-sms/threadID?recipient=9878782944 from pid=337, uid=10038 requires android.permission.READ_SMS
     at android.os.Parcel.readException(Parcel.java:1247)
     at android.database.DatabaseUtils.readExceptionFromParcel(DatabaseUtils.java:160)
     at android.database.DatabaseUtils.readExceptionFromParcel(DatabaseUtils.java:114)
     at android.content.ContentProviderProxy.insert(ContentProviderNative.java:408)
     at android.content.ContentResolver.insert(ContentResolver.java:587)
     at ir.fadesign.sms.Main$1.onClick(Main.java:25)
     at android.view.View.performClick(View.java:2408)
     at android.view.View$PerformClick.run(View.java:8816)
     at android.os.Handler.handleCallback(Handler.java:587)
     at android.os.Handler.dispatchMessage(Handler.java:92)
     at android.os.Looper.loop(Looper.java:123)
     at android.app.ActivityThread.main(ActivityThread.java:4627)
     at java.lang.reflect.Method.invokeNative(Native Method)
     at java.lang.reflect.Method.invoke(Method.java:521)
     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:868)
     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:626)
     at dalvik.system.NativeStart.main(Native Method)
</code></pre>
