Questions tagged [android-sms]

Working with SMS in Android. If asking about SMS in general, use sms tag.

106 questions
2
votes
1 answer

Uri null after null check - SMS Content provider [Android SDK 30+]

public void save(AppCompatActivity context, SMSListener listener) { mContext = context; try { // String mode = SMSData.getSMS_typeText(type_internal); ContentValues values = returnContentValues(); // content values …
exploitr
  • 843
  • 1
  • 14
  • 27
2
votes
1 answer

Android RoleManager remove role RoleManager.ROLE_SMS for own package

I have sms backup app that backup and restore SMS only so when i restore sms I need to set default Massage App. then after Restore i don't need to stay default Massage App. So my question is how to remove my app default to Massage App. and also for…
sk panchal
  • 159
  • 1
  • 13
2
votes
1 answer

Error While Sending Large Sentence As SMS using Array in java using default SMS service over SIM

I am having trouble on sending SMS from APP. I the App is working Fine on some Devices like Samsung, Nokia etc. But Not working on devices like OPPO, VIVO devices. All the devices I tested was SDK29 (ANDROID 10). ps: I am newbie here Below is my…
ANI
  • 43
  • 4
2
votes
1 answer

Android SMS Verification API result code is always 0

I implemented the Android SMS Verification API on activities and fragments on the same project and it went well. My problem is with fragments in tabs. No matter what I do, onActivityResult always returns result code 0 when "Allow" is pressed. Here's…
Lendl Leyba
  • 2,287
  • 3
  • 34
  • 49
2
votes
1 answer

BroadcastReceiver not execute on release mode

I try implement Request SMS Verification in an Android App and my code work like a charm in debug but when i generate sign apk app and run it as release my BroadcastReceiver class seems not execute , i try so many ways like define my receiver as…
Erfan
  • 3,059
  • 3
  • 22
  • 49
2
votes
0 answers

Need to detect SMS Sent in android

I know this question is way old and may be duplicate, but I have a particular query based on it for which I am still trying to find the solution. As far as I know, ContentObserver on URI content://sms will be triggered when ever there is change in…
Vaibs
  • 1,128
  • 3
  • 16
  • 36
2
votes
1 answer

Return to onActivityResult after SMS send

I would like to have a SMS intent be populated for the user, then launch the intent and after the SMS is sent, return to my app to continue to execute code. So thus far I use this to setup the Intent: Uri uri = Uri.parse("smsto:" +…
Marnus Steyn
  • 1,053
  • 2
  • 16
  • 44
2
votes
2 answers

Sending Sms in Android on reaching a Location

I am an absolute beginner in android.In this code i want to send sms on reaching a particular location. My app crashes if i put Sms manager outside onlocationchange()function.So it is sending continuous sms if Im not coming out of the 10m distance.I…
2
votes
0 answers

Querying for SMS sent via Project Fi

When an SMS is sent/received on a Project Fi Android phone using Hangouts/Messenger how is it stored? When querying for messages using Android's sms or mms ContentProviders I'm only getting sms messages sent/received when the phone wasn't part of…
marmor
  • 27,641
  • 11
  • 107
  • 150
2
votes
3 answers

Send SMS won't startActivity

I want to send SMS from my application, for which I have written below code, which is pretty simple. But the issue I am facing is, No activity is started on sending message Method to send a message: private void sendSMS(Context context, String…
John Bravado
  • 137
  • 4
  • 10
2
votes
1 answer

Cannot delete SMS programatically (Default SMS app set)

I try to delete all SMS from my phone with this func: public void wipeOutAllSMS(Context context) { try { int rowsDeleted = 0; Uri uriSms = Uri.parse("content://sms/inbox"); Cursor c =…
Adam Varhegyi
  • 11,307
  • 33
  • 124
  • 222
1
vote
0 answers

SMS_RECEIVED Broadcast receiver stops working after some time

I'm working on a utility application in which when an SMS is received with a specific message I need to send a reply message. To know the sms_received event i used a broadcast receiver. Below it the code of it in the manifest file.
1
vote
0 answers

How do I send an SMS which has an image along-with the text body in Android (java)?

I am looking for a way to send an sms, which has an image along with the message body to a series of numbers with the help of a for loop. I've figured out a way of automatically sending simple text message to a CSV list of numbers using the below…
Sonal
  • 137
  • 2
  • 13
1
vote
1 answer

Android: If I send an SMS using SmsManager, does it automatically resend failed sms?

If I'm sending an SMS from my app using SmsManager and the SMS fails to send, does the SmsManager automatically retry sending SMS for me - or do I have to manage this myself in code?
user873578
1
vote
1 answer

Android Kotin: asking the user to set the app as Default SMS handler is not working

I am building an Android app using Kotlin. I am trying building my app as Default SMS handler because it is asking for SMS permissions so that I need to make sure that it imply with the Google PlayStore's policy. But it is not showing any popup or…
Wai Yan Hein
  • 13,651
  • 35
  • 180
  • 372