I get this in the Xcode console when tapping on my App's share via Message: The Mail one works perfectly fine however. The Message controller never displays obviously, which makes this annoying in a shipped app.
Remote compose controller timed out (YES)!
Is this an Apple bug? It only started to happen today.
Code:
if(SYSTEM_VERSION_GREATER_THAN_OR_EQUAL_TO(@"6.0"))
{
NSString *textToShare = [NSString stringWithFormat:@"test"];
NSArray *activityItems = [[NSArray alloc] initWithObjects:textToShare, nil];
UIActivityViewController *activityVC = [[UIActivityViewController alloc] initWithActivityItems:activityItems
applicationActivities:nil];
activityVC.completionHandler = ^(NSString *activityType, BOOL completed)
{
NSLog(@" activityType: %@", activityType);
NSLog(@" completed: %i", completed);
};
if(UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad)
{
self.popover = [[UIPopoverController alloc] initWithContentViewController:activityVC];
CGRect rect = [[UIScreen mainScreen] bounds];
[self.popover
presentPopoverFromRect:rect inView:self.view permittedArrowDirections:0 animated:YES];
}
else
{
[self presentViewController:activityVC animated:YES completion:nil];
}
}
There's nothing wrong with this code. It works without problem on my devices. You might want to try rebooting your device or trying on another device.
The few isolated references that I found to this problem were related to beta versions of iOS 6 or other people suffering from the occasional crash, so perhaps we're just slowing working through the kinks in this messaging UI.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With