I created a small project for Apple Watch to interact with its parent application.
So, I created a clock set extension in my existing iOS project, but when on the Watch side it calls the openparent application in the response block, it gets
" Error: Domain Error = FBSOpenApplicationErrorDomain Code = 5" The operation could not be completed. (FBSOpenApplicationErrorDomain error 5.) ".
What does this error mean? Is there any targeted question? Please find the following code:
Clockwork Side:
- (IBAction)satusButtonClicked {
NSLog(@"StausButtonClicked");
NSDictionary *senddict=[[NSDictionary alloc] initWithObjects:@[@"5",@"Two",@"Three"] forKeys:@[@"1",@"2",@"3"]];
[InterfaceController openParentApplication:senddict reply:^(NSDictionary *replyInfo, NSError *error) {
NSLog(@"ReplyReceived : %lu",(unsigned long)[replyInfo count]);
NSLog(@"Reply Info: %@", replyInfo);
NSLog(@"Error: %@", error);
}];
}
iOS side:
-(void)application:(UIApplication *)application handleWatchKitExtensionRequest:(NSDictionary *)userInfo reply:(void (^)(NSDictionary *))reply
{
NSLog(@"Watckit call received");
reply(@{@"Score": @"234"});
source
share