I have used this code to send SMS
String phoneNumber="000000000000";
Intent intent = new Intent(Intent.ACTION_SENDTO);
intent.setData(Uri.parse("smsto:" + phoneNumber));
intent.putExtra("address", phoneNumber);
intent.putExtra("sms_body", smsContent);
startActivityForResult(intent,RESULT_CODE);
this will send SMS properly
But i had an issue on onActivityResult() ,the result code is always getting 0 , I don't know how to solve this issue,and How will i know that the SMS has been sent or not ?
then tried with SmsSendObserver.SmsSendListener interface to receive the callback.but it is giving an error
java.lang.SecurityException: Permission Denial: reading com.android.providers.telephony.SmsProvider uri content://sms/ from pid=29471, uid=10277 requires android.permission.READ_SMS, or grantUriPermission()
and i can't give READ_SMS permission due to the google play permission policy update ,so how can i grant URI permission