Android SDK MMS

user160231 picture user160231 · Dec 16, 2009 · Viewed 21.7k times · Source

Does anyone know how to programmatically send a MMS via the Android SDK? Any version of the SDK will do, just need to know where to get started. I know how to send / receive SMS, I now need to add a picture to the message before sending.

Answer

Billy Bob Bain picture Billy Bob Bain · Dec 16, 2009

This worked for me.

Intent sendIntent = new Intent(Intent.ACTION_SEND); 
sendIntent.putExtra("sms_body", "some text"); 
sendIntent.putExtra(Intent.EXTRA_STREAM, Uri.parse(url));
sendIntent.setType("image/png"); 

The url being passed to the Uri.parse method should be of the form used to access the media store such as content://media/external/images/media/23.

From the series at jtribe.