Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Attach image in Native SMS/MMS Application on iPhone

Tags:

iphone

sms

ios4

i want to send an image through native application in iphone.

I have searched a lot on web but cant find anything.

is it possible with iOS?

Please do help...

like image 296
GameLoading Avatar asked Jan 22 '11 10:01

GameLoading


1 Answers

MFMessageComposeViewController is the only documented API for creating SMS messages programmatically. It does not currently allow MMS but you can file a bug report for the feature request. In the meantime, you can either:

-use MFMailComposeViewController which does allow image attachments via -(void)addAttachmentData:(NSData*)attachment mimeType:(NSString*)mimeType fileName:(NSString*)filename

-or like Aurum mentioned, save the image to the photo library and instruct the user to send it with the native "Messages" app.

like image 51
Keller Avatar answered Nov 12 '22 06:11

Keller