Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

MFMailComposeViewController with recipient display-name as well as email address

I find that I can

[picker setToRecipients:[NSArray arrayWithObject:@"My Name <[email protected]>"]];

and it nicely displays "My Name" in the To: field when composing the email, and delivers it correctly to [email protected], on my iPad device. Looks good in the iPad simulator too (can't send though of course).

But the iPhone simulator just shows "1 recipient" on the compose screen. Don't know whether it would send it ok or not, don't have an iPhone device handy to test that.

Has anyone else gone down this path? Any way of getting the display-name on the iPhone compose screen?

Thanks

like image 864
Steve Rogers Avatar asked Nov 25 '11 08:11

Steve Rogers


1 Answers

OK got it. There is a 40-character limit on the display name. When I figured this out and googled "email display-name 40" I find there other (non-Apple) references to a 40-char limit. RFC possibly. Perhaps I should have included the real display-name and email address in my question ;)

like image 179
Steve Rogers Avatar answered Sep 17 '22 15:09

Steve Rogers