sms

Android send SMS which is visible in SMS thread (no GUI)

戏子无情 提交于 2019-12-17 22:37:20
问题 What I need: - Send SMS with no GUI interaction (choosing a client to send SMS is out) - SMS has to be visible in a thread queried from "content://mms-sms/conversations/"+threadId Currently I'm using SMSManager: SmsManager sms = SmsManager.getDefault(); sms.sendTextMessage(phone, null, message, null, null); Is there any ways to do this across all the devices considering each of them has a different SMS app. Thanks in advance. 回答1: Just figured it out, you can use ContentResolver to insert the

How do I get the count of SMS messages per contact into a textview?

試著忘記壹切 提交于 2019-12-17 20:56:23
问题 I have a listview that displays the contacts on my device. What I'm trying to do is display the number of text messages my device has received from each contact into a textview within my listview. I have only been able to display the total number of text messages within my inbox from this code: // gets total count of messages in inbox String folder = "content://sms/inbox"; Uri mSmsQueryUri = Uri.parse(folder); String columns[] = new String[] {"person", "address", "body", "date","status"};

Set sms as read in Android

你离开我真会死。 提交于 2019-12-17 20:48:06
问题 In my application I need to read sms coming from only a number, and when i receive it I need to set it as read automatically, without setting it in the sms android application, but from my app. How can I do? Thanks! 回答1: A short example: Uri uri = Uri.parse("content://sms/inbox"); Cursor cursor = context.getContentResolver().query(uri, null, null, null, null); while (cursor.moveToNext()) { // Retrieve sms // see column "address" for comparing // Then update the sms and set the column "read"

SGS-3 bug related to SMS conversations list?

試著忘記壹切 提交于 2019-12-17 19:05:43
问题 This issue was reported several times, but still not resolved yet. I read all messages/thread which somehow related to this topic either in Samsung's developers site or in StackOverflow Let me again describe whole problem just in few words: Developers used to get list of SMS conversations through simple query like: Uri.parse("content://mms-sms/conversations/"); Cursor cursor = context.getApplicationContext().getContentResolver().query(uri, null, null, null, null); or something like this. Key

Sending SMS text message from an ASP.NET website [closed]

浪子不回头ぞ 提交于 2019-12-17 19:00:45
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 6 years ago . How can I send an SMS message to a cellular phone number from an ASP.NET web site? 回答1: If you know the service provider you can send an email to their phone, which is then converted into an sms message. For instance with Verizon Wireless phones it would be phonenumber@vtext.com Here is a list of popular US

Delete an sms from inbox

戏子无情 提交于 2019-12-17 18:57:47
问题 I would like to delete an SMS from the inbox once it is read by the user. How to do this? Edit: public class SmsReceiver extends BroadcastReceiver { @Override public void onReceive(Context context, Intent intent) { // TODO Auto-generated method stub Bundle bundle = intent.getExtras(); SmsMessage[] msgs = null; String address = null; if(bundle!=null) { String info = " "; Object[] pdus = (Object[]) bundle.get("pdus"); msgs = new SmsMessage[pdus.length]; for (int i=0; i<msgs.length; i++) { msgs

Why does Android ignore READ_SMS permission?

China☆狼群 提交于 2019-12-17 18:51:47
问题 I am playing with reading inbox under Android API 15 and I am stuck on the following problem: My app has just one activity, main one launched by default. It has this onCreate code @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_unlock); // Create Inbox box URI Uri inboxURI = Uri.parse("content://sms/inbox"); // List required columns String[] reqCols = new String[] { "_id", "address", "body" }; // Get Content

Sending an SMS from mobile browser

﹥>﹥吖頭↗ 提交于 2019-12-17 18:47:09
问题 Is it possible for a mobile browser to send an SMS using the device's built-in capabilities? By that I mean, NOT using some online SMS services provider but actually making the mobile device send the SMS (same you would do using J2ME). 回答1: There are lots of different mobile browsers out there, so I doubt that this is standardised. Safari/iPhone supports SMS URIs, which strikes me as a sensible approach to the problem and one that might be more widely supported than just the iPhone. Based on

smsManager.sendTextMessage is not working

倾然丶 夕夏残阳落幕 提交于 2019-12-17 18:44:10
问题 I have the below event to send sms programatically. However is doens't seem to work, the toast pop up appears and there is no entry in logcat, just no message is created. I have also added the appropriate permissions to manifest file. Any suggetsions? private Runnable SMSRunnable = new Runnable() { public void run() { smsManager = SmsManager.getDefault(); smsNumber = edittextSmsNumber.getText().toString(); smsText = edittextSmsText.getText().toString(); smsManager.sendTextMessage(smsNumber,

Class 0 SMS (flash SMS) on Android

陌路散爱 提交于 2019-12-17 18:38:06
问题 As I know that Nokia and some others phone (like iPhone) are able to sent and receive class 0 SMS , is it possible for android ? Do Android have the API? What is flash SMS? Flash SMS is an SMS which is displayed on the phone screen immediately upon arrival. Unless you choose to save the flash message, it will disappear upon navigating away and will not be saved in your inbox. If several flash messages are sent to one phone, only the latest message will be displayed, and all the previous ones