问题
Right now I'm trying to create an SMS intent with a populated number.
Intent sendIntent = new Intent(Intent.ACTION_VIEW);
sendIntent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
sendIntent.setData(Uri.parse("smsto:"+phoneNumber));
context.startActivity(sendIntent);
setResultData(null);
this works fine with the phone's SMS app, however the problem is that if Google Voice is installed and the user selects this option rather than the normal SMS app, google voice won't populate the number.
Is there a way to populate the number in google voice with an SMS intent?
回答1:
You can check here "list of google voice intents and arguments" http://groups.google.com/group/appinventor/browse_thread/thread/2e857e86f113109b?tvc=2&pli=1
回答2:
This blog post seems to be about what you are after: the Intent setting the phone number for the SMS. The redundant setting of metadata maybe helps Google Voice-enhanced phones.
http://juristr.com/blog/2009/12/android-sms-activity-doesnt-fill-phone/
来源:https://stackoverflow.com/questions/5386326/google-voice-sms-intent