mfmessagecomposeview

MFMessageComposer cancel button not visible in iOS 11

老子叫甜甜 提交于 2019-12-13 05:31:48
问题 The cancel button on right top corner after a message composer has been presented is not visible in iOS 11 devices. As shown in the screenshot, cancel button works but is not visible. Once we press on it, the screen dismisses. 回答1: I have tried like this: class ViewController: UIViewController, MFMessageComposeViewControllerDelegate { override func viewDidLoad() { super.viewDidLoad() // Do any additional setup after loading the view, typically from a nib. } override func

UIActivityViewController With Alternate Filename?

≡放荡痞女 提交于 2019-12-12 06:48:52
问题 I am sharing an audio recording via the UIActivityViewController. When the audio file shares via email or iMessage, it shows the underlying name of the audio file without any apparent way of changing it. NSArray *activityItems = [NSArray arrayWithObjects:self.audioPlayer.url, nil]; UIActivityViewController *avc = [[UIActivityViewController alloc] initWithActivityItems:activityItems applicationActivities:nil]; [self presentViewController:avc animated:YES completion:nil]; If I don't use the

Can't send Video to MFMessageComposeViewController

故事扮演 提交于 2019-12-11 17:54:42
问题 I have to send Video through message. I attached 30KB size of video. But it alerts "Video is too long". Below i mentioned the code to send video through message. NSString *message = [NSString stringWithFormat:@"Download this Video!"]; MFMessageComposeViewController *messageController = [[MFMessageComposeViewController alloc] init]; messageController.messageComposeDelegate = self; [messageController setBody:message]; if ([MFMessageComposeViewController canSendAttachments]) { NSLog(@

iphone 4.0 sending sms programmatically

依然范特西╮ 提交于 2019-12-11 02:32:57
问题 I am working on a simple application in which I need send sms programmatically to my friends. so write below code for sending sms . MFMessageComposeViewController *picker = [[[MFMessageComposeViewController alloc] init]autorelease]; if([MFMessageComposeViewController canSendText]) { picker.messageComposeDelegate = self; picker.recipients =[NSArray arrayWithObject:@"123"]; picker.body=@"hello"; [self presentModalViewController:picker animated:YES]; } but I do not want to load message picker

MFMessageComposeViewController not working

谁都会走 提交于 2019-12-10 15:45:05
问题 I have a simple method that gets one argument and then sends a message. It is not working. Code: - (void)sendSMS:(NSString *)text { MFMessageComposeViewController *viewController = [[MFMessageComposeViewController alloc] init]; viewController.body = text; viewControllerM.mailComposeDelegate = self; [self presentViewController:viewController animated:YES completion:nil]; } What's wrong? 回答1: You need to set the delegate: MFMessageComposeViewController *controller = [[

MFMessageComposeViewController issues in iOS8

徘徊边缘 提交于 2019-12-06 09:58:19
问题 I've run into a strange bug with MFMessageComposeViewController in iOS8, that is only reproducible within my own app. It's affecting the app right now in the App Store, built with the iOS7 SDK running on iOS8, as well with the iOS8 SDK in my own test devices (iPhone and iPad) The issue is that when I bring up the MFMessageComposeViewController, it shows me the controller without a text field or a Send button anymore. I haven't changed my code between iOS7 and iOS8, so not sure why this is

app get crashed while navigating to RootViewController from Message popup

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-06 07:32:18
问题 I used MFMessageComposeViewController class for sending messages. My app get crashed in a particular situation. i e, When Message UI popup comes, user presses home button, app goes background and when come back, I wrote the code to navigate to the root view controller in applicationDidBecomeActive delegate. Please let me know if any suggestions? 回答1: In app delegate you are assigning the rootviewcontroller and in applicationDidBecomeActive you are redirecting into rootviewcontroller , why not

Presenting MFMessageComposeViewController broken in iOS 6

℡╲_俬逩灬. 提交于 2019-12-06 04:42:15
My app presents a MFMessageComposeViewController modally. It was working perfectly fine in iOS 5 (both on the simulator and on the device). After I upgraded my iPhone to 6, it simply doesn’t work anymore. The app freezes for like 10 seconds, then this message appears in the debugger "Remote compose controller timed out (YES)!" And the modal view does not show up. I searched extensively on stackoverflow and on the web, and couldn’t find any solution. As a final resort, I downloaded and ran the sample code of apple, "MessageComposer" and, alas, even in apple code it does not work on iOS 6. I`m

Do I have to dismiss a MFMessageComposeViewController in its didFinishWithResult delegate method?

跟風遠走 提交于 2019-12-06 01:34:26
I'm trying to allow the user to send multiple text messages in succession in a MFMessageComposeViewController, but if I don't dismiss the controller in the didFinishWithResult delegate method, the Cancel button in the top right corner becomes disabled, and the user has no way of getting out of the text message interface. Is the MFMessageComposeViewController only for sending one-off messages? func messageComposeViewController(controller: MFMessageComposeViewController!, didFinishWithResult result: MessageComposeResult) { if result.value == MessageComposeResultCancelled.value { self

MFMessageComposeViewController issues in iOS8

微笑、不失礼 提交于 2019-12-04 16:48:10
I've run into a strange bug with MFMessageComposeViewController in iOS8, that is only reproducible within my own app. It's affecting the app right now in the App Store, built with the iOS7 SDK running on iOS8, as well with the iOS8 SDK in my own test devices (iPhone and iPad) The issue is that when I bring up the MFMessageComposeViewController, it shows me the controller without a text field or a Send button anymore. I haven't changed my code between iOS7 and iOS8, so not sure why this is happening. The code itself is very simple: MFMessageComposeViewController *picker = [