6

I am developing a desktop application which deals with images. I want to provide a feature that e-mails selected image (single image) to the default e-mail client. So, I am using mailto: as follows:

NSString *eMail = [NSString stringWithFormat: @"mailto:?subject=Test&body=Image];
[[NSWorkspace sharedWorkspace] openURL: [NSURL URLWithString: eMail]];      

How do I send the image as an attachment using mailto:?

I tried the following: But, it does not work.

NSString *eMail = [NSString stringWithFormat: @"mailto:?subject=Test&body=Image&attachment=%@", @"Test.png"];
[[NSWorkspace sharedWorkspace] openURL: [NSURL URLWithString: eMail]];      

What can I try next?

halfer
  • 19,824
  • 17
  • 99
  • 186
spd
  • 2,114
  • 1
  • 29
  • 54

0 Answers0