IPhone : presentViewController didnt work appdelegate

on Thursday, April 9, 2015

on last line my app is crash



//present view controller to add the pass to the library
PKAddPassesViewController *vc = [[PKAddPassesViewController alloc] initWithPass:pass];
[vc setDelegate:(id)self.delegate];
[self.delegate presentViewController:vc animated:YES completion:nil];


im call this method in AppDelegate.m in method



- (void)application:(UIApplication*)application didReceiveRemoteNotification:
(NSDictionary*)userInfo


Here I tried to use different delegates and tried use notification



self.window.rootViewController;


all times error



reason: 'Application tried to present a nil modal view controller on target <VVRightManuViewController: 0x15dd28460>.'

0 comments:

Post a Comment