Jump to content

- - - - -

MFMailComposer Email Results From Core Data

  • Please log in to reply
No replies to this topic

#1 designwerks


    Advanced Member

  • STV 5.0 Std
  • PipPipPipPipPip
  • 141 posts
  • LocationKingsville, Ontario, Canada
Reputation: 23

Posted 06 December 2017 - 09:05 AM

Core data functions nicely. What might be a code snippet to reference the results of the core data and insert into MFMailComposeViewController directly inline (not as an attachment) using isHTML:Yes... I have used this code in another app and it plays nicely, but it is using literal strings...


NSString *emailBody = [NSString stringWithFormat:@"<p>Stats...</p>

<p><b>Laps Completed: %@</b></p><p>Goal: %@ laps</p>
<p>Time To Complete: %@ (h:m:s)</p>
<p>%f&#37 completion ratio</p>",
self.lapLabel.text, self.goal.text, self.timeLabel.text,

[mail setMessageBody:emailBody isHTML:YES];


I have tried the following code, but the result is blank... (no error, but a "blank info" area in email composer)


NSString *emailBody = [NSString stringWithFormat:@"<p>Stats...</p><p><b>Related Tasks: %@ %@</b></p>", self.tableViewModel.tableView, self.tableViewModel = [self loadPlantsModel]];





Edited by designwerks, 06 December 2017 - 09:32 AM.

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users