Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781
[phpBB Debug] PHP Notice: in file /includes/session.php on line 1007: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/session.php on line 1007: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/session.php on line 1007: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)

Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781

Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781

Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4362: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4364: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4365: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4366: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
anddev.org • View topic - How to specify SMS intent recipient

How to specify SMS intent recipient

Put your problem here if it does not fit any of the other categories.

How to specify SMS intent recipient

Postby PaulFake » Sun Oct 11, 2009 11:05 am

Hello,

I am launching an SMS activity, but I don't know how to specify the recipient so that the number will appear in the "To" field. I was hoping something like the following would work, but it doesn't.

Syntax: [ Download ] [ Hide ]
Using java Syntax Highlighting
  1.  
  2. Intent sendIntent = new Intent(Intent.ACTION_VIEW, Uri.parse("sms:8675309"));
  3.  
  4. sendIntent.putExtra("sms_body", "");
  5.  
  6. sendIntent.setType("vnd.android-dir/mms-sms");
  7.  
  8. startActivity(sendIntent);
  9.  
  10.  
Parsed in 0.013 seconds, using GeSHi 1.0.8.4
PaulFake
Junior Developer
Junior Developer
 
Posts: 21
Joined: Wed Aug 26, 2009 1:05 am

Top

Postby PaulFake » Sun Oct 11, 2009 11:16 am

No sooner do I post than I solve my own problem:

Syntax: [ Download ] [ Hide ]
Using java Syntax Highlighting
  1.  
  2. Intent sendIntent = new Intent(Intent.ACTION_VIEW, Uri.parse("smsto:5555555"));
  3.  
  4. sendIntent.putExtra("sms_body", "");
  5.  
  6. sendIntent.setClassName("com.android.mms", "com.android.mms.ui.ComposeMessageActivity");
  7.  
  8. startActivity(sendIntent);
  9.  
  10.  
Parsed in 0.011 seconds, using GeSHi 1.0.8.4


It's a combination of using "smsto" and ComposeMessageActivity.
PaulFake
Junior Developer
Junior Developer
 
Posts: 21
Joined: Wed Aug 26, 2009 1:05 am

Top

Return to Other Coding-Problems

Who is online

Users browsing this forum: MSNbot Media, Yahoo [Bot] and 12 guests