10

Currently, I can set a button to take a picture, but I'm unsure how to pass this as an attachment for an email in the same view.
The view is for a quote and allows the user to enter data into a few fields then has a button to email said data.

vikingosegundo
  • 52,040
  • 14
  • 137
  • 178
fmi
  • 512
  • 4
  • 14
  • [How can I send mail from an iPhone application](http://stackoverflow.com/questions/310946/how-can-i-send-mail-from-an-iphone-application) – beryllium Nov 20 '11 at 19:09

2 Answers2

9

Maybe this link would satisfy your requirement for the second half of the question...

http://www.ericd.net/2009/04/sending-email-from-iphone-application.html

    UIImage *myImage = [UIImage imageNamed:@"mobiletuts-logo.png"];
    NSData *imageData = UIImagePNGRepresentation(myImage);
    [mailer addAttachmentData:imageData mimeType:@"image/png"   fileName:@"mobiletutsImage"];

Courtesy:

http://mobile.tutsplus.com/tutorials/iphone/mfmailcomposeviewcontroller/

rohan-patel
  • 5,772
  • 5
  • 45
  • 68
  • Thanks for the help...but I'm trying to 'push' the file from the camera as an attachment without having to save it first. – fmi Nov 20 '11 at 20:28
  • You can save it to library and access photo from there..Its just a suggestion. – rohan-patel Nov 21 '11 at 03:37
1

Check out Apple's MailComposer example http://developer.apple.com/library/ios/#samplecode/MailComposer/Introduction/Intro.html#//apple_ref/doc/uid/DTS40008865

syclonefx
  • 2,830
  • 1
  • 21
  • 24