unable to receive callback from second view controller

后端 未结 1 1609
我在风中等你
我在风中等你 2021-01-28 09:59

I have got two view controllers. Im trying to pass data to the previous viewcontroller

I have the following code in my second view controller CEPeoplePickerNaviga

相关标签:
1条回答
  • 2021-01-28 10:41

    Your code seems absolutely correct but to get around all the possibilities. Can you check whether your done button action has a check to know if the delegate methods is available or not in that class?

    if ([self.viewCrtrlDelegate respondsToSelector:@selector(previousViewController:item:)]) {
        [self.viewCrtrlDelegate previousViewController:self item:@"Here I am"];
        [self dismissViewControllerAnimated:YES completion:nil];
    }
    else{
       NSLog(@"Your delegate was properly set");
    }
    
    0 讨论(0)
提交回复
热议问题