how to 开发者_高级运维attach images from iphone saved photo album to MFMailComposerView and send through mail...plese help me..is there any sample application source code available
Say image
is the image you want to attach.
NSData *attachmentData = UIImageJPEGRepresentation(image, 1.0);
...
MFMailComposeViewController *mailComposer = [[MFMailComposeViewController alloc] init];
...
[mailComposer addAttachmentData:attachmentData mimeType:@"image/jpeg" fileName:@"attachment.jpeg"];
...
// Push it on to the screen.
精彩评论