¿Estoy haciendo algo tonto? Puedo pre-llenado y correo electrónico bien, pero el "\ r \ n" se ignora en el emailBody:Nueva línea y devuelve ignorado en setMessageBody
- (void) sendEventInEmail
{
MFMailComposeViewController *picker = [[MFMailComposeViewController alloc] init];
picker.mailComposeDelegate = self;
NSString *emailSubject = [eventDictionary objectForKey:EVENT_NAME_KEY];
[picker setSubject:emailSubject];
// Fill out the email body text
NSString *iTunesLink = @"http://itunes.apple.com/gb/app/whats-on-reading/id347859140?mt=8"; // Link to iTune App link
NSString *content = [eventDictionary objectForKey:@"Description"];
NSString *emailBody = [NSString stringWithFormat:@"%@\r\nSent using <a href = '%@'>What's On Reading</a> for the iPhone.", content, iTunesLink];
[picker setMessageBody:emailBody isHTML:YES];
picker.navigationBar.barStyle = UIBarStyleBlack;
[self presentModalViewController:picker animated:YES];
[picker release];
}
Saludos
de Dave
Tenía HTML configurado en SÍ, swi tched to no y nuevas líneas trabajadas. ¿Qué es "y códigos de formato"? – quantumpotato
@quantumpotato: la tuya es la única solución que funcionó –