I use the following code to start the SMS application:
Intent smsIntent=new Intent(Intent.ACTION_SENDTO, Uri.parse("sms:"));
smsIntent.putExtra("sms_body", "Message Body");
startActivity(smsIntent);
It works fine if user selects standard "Messaging" application. But if user selects GV the message body text is ignored.
I have also tried the following as suggested in some forums:
smsIntent.putExtra(Intent.EXTRA_TEXT, "Message Body");
I have searched all the forums I know of and tried lot of things. Nothing worked for me. Am I missing something here? Does GV need a special handing that it can’t be treated as regular “Messaging” app?
If you have the Google Voice app installed, you also get text messages there. To stop getting 2 notifications, turn off Google Voice text forwarding. Then you'll only get texts in the Google Voice app.
Google Voice Actions gives you one API to support Android phones, tablets, and Android Wear watches.
What is Google Voice's sending limit per text message? You can send messages up to 160 characters to any non-Google voice number. Anything above that limit will instead go out as multiple messages. Texts sent to another Google Voice number won't have a text cap.
Here are some thoughts that might point you in the right direction:
what is the difference between ACTION_SENDTO and ACTION_VIEW when sending sms?
Here's a third party library for accessing Google Voice: http://code.google.com/p/google-voice-java/ ...except it directly accesses Google Voice via its web URLs...
Here's some old (2010) Android MMS source where they manually accessed Google Voice, which might give some bonus hints:
Also try putting it in an extra called "data"
or "pdudata"
Also, here's some more (old?) source mentioning some intent extras including "android.mms.extra.MESSAGE"
Hopefully one of these help you out...
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With