Reputation: 690
I have to display the setup email screen in iOS if user has not already setup an email.
So when [MFMailComposeViewController canSendMail]
returns NO
I need to display following screen
Is this possible ? How can I achieve it ?
Upvotes: 0
Views: 82
Reputation: 936
Not sure but you can try this:
NSString *recipients = @"mailto:[email protected]?subject=subjecthere";
NSString *body = @"&body=bodyHere";
NSString *email = [NSString stringWithFormat:@"%@%@", recipients, body];
email = [email stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding];
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:email]];
Upvotes: 2