uistoryboardsegue

prepareForSegue destination controller property not being set

℡╲_俬逩灬. 提交于 2019-12-02 04:36:45
问题 Here's my prepareForSegue: -(void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender{ if ([segue.identifier isEqual:@"cameraToRollsSegue"]){ ALRollsTableViewController *rollsTableViewController = (ALRollsTableViewController *)[segue destinationViewController]; Camera *c = [self.fetchedResultsController objectAtIndexPath:[self.tableView indexPathForSelectedRow]]; NSLog(@"CAMERA FROM INSIDE PREPARE FOR SEQUE: %@", c); rollsTableViewController.selectedCamera = c; } } I verify that the

NSGenericException: This coder requires that replaced objects be returned from initWithCoder

大兔子大兔子 提交于 2019-12-02 04:10:53
I was running my iPhone app just fine yesterday. Today I'm getting this crash: *** Terminating app due to uncaught exception 'NSGenericException', reason: 'This coder requires that replaced objects be returned from initWithCoder:' It happens when going from one view to another with storyboard segue (also tried it programmatically). The destination view controller is a UITableViewController with nothing strange. I've rolled back my code to check if anything changed that causes this crash but nothing. Latest test build I made still works fine with same code. Anybody have any idea what could be

Attempting to segue from Objective-C to Swift VC

烂漫一生 提交于 2019-12-02 03:51:31
i'm trying to segue from objective-c to swift. However when I try this using the object below I receive the following error I don't know what i'm doing wrong, i've setup the segue on the storyboard and assigned it to the same ID, created the prepare function and the perform. - (void)renderer:(id<SCNSceneRenderer>)renderer willRenderScene:(SCNScene *)scene atTime:(NSTimeInterval)time { // Look for trackables, and draw on each found one. size_t trackableCount = trackableIds.size(); for (size_t i = 0; i < trackableCount; i++) { // NSLog(@"this is the variable value: %d", trackableIds[i]); // Find

How to create a segue from UIViewController to a UISplitViewController

六月ゝ 毕业季﹏ 提交于 2019-12-02 02:34:48
问题 Here's my setup for an iPad app. I created a new project using the Single View Application with UIStoryboard . XCode created the main UIViewController as the entry point. In the view I placed a toolbar with a button. I then insterted a UISplitViewController to the storboard. What I want is from the toolbar to have a button that will load the split view with master/detail tables. I tried to click on the button and drag to the splitviewcontroller, which created a segue, but every combination I

prepareForSegue destination controller property not being set

柔情痞子 提交于 2019-12-02 01:29:06
Here's my prepareForSegue: -(void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender{ if ([segue.identifier isEqual:@"cameraToRollsSegue"]){ ALRollsTableViewController *rollsTableViewController = (ALRollsTableViewController *)[segue destinationViewController]; Camera *c = [self.fetchedResultsController objectAtIndexPath:[self.tableView indexPathForSelectedRow]]; NSLog(@"CAMERA FROM INSIDE PREPARE FOR SEQUE: %@", c); rollsTableViewController.selectedCamera = c; } } I verify that the camera is not null with NSLog: CAMERA FROM INSIDE PREPARE FOR SEQUE: <Camera: 0x8dc1400> (entity:

How to create a segue from UIViewController to a UISplitViewController

跟風遠走 提交于 2019-12-02 01:02:39
Here's my setup for an iPad app. I created a new project using the Single View Application with UIStoryboard . XCode created the main UIViewController as the entry point. In the view I placed a toolbar with a button. I then insterted a UISplitViewController to the storboard. What I want is from the toolbar to have a button that will load the split view with master/detail tables. I tried to click on the button and drag to the splitviewcontroller, which created a segue, but every combination I created failed to run and crashed. My toolbar will have many other buttons which will load other views.

How to detect when a popover is dismissed in iOS 9

怎甘沉沦 提交于 2019-12-01 14:20:08
问题 I'm updating an app to use universal storyboards. I've created a popover segue to a new viewcontroller using interface builder by dragging from a button to my new viewcontroller and selecting 'Present As Popover' as the kind of segue. When the user presses outside of the popover (dismissing it) I need to be notified in the presenting view controller so I can undo their actions. How can I do this? Normally I would have created the popover manually and made my viewcontroller the popover's

shouldPerformSegueWithIdentifier issue

99封情书 提交于 2019-12-01 13:59:24
I tried too much to solve my bellow issue but i am failed.Please help me to solve this issue. I have login view and after validating id and password i am pushing it to next view controller.Please check bellow image. Issue - When Id and Password is correct it's pushing to next view controller but after 2 clicks on login button. Code - ServiceManager.m -(void)initGetAppServiceRequestWithUrl:(NSString *)baseUrl onCompletion: (ServiceCompletionHandler)handler { NSString *fullUrl = [NSString stringWithFormat:@"%@",[baseUrl stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding]];

Passing data from annotations to detail view iOS using storyboard

一世执手 提交于 2019-12-01 13:04:00
问题 I'm trying to pass the data that I have currently loaded into annotations via Google Places API into a detail view controller that I have created via storyboard with a segue. I have it properly loading the detail view controller upon clicking the detail disclosure on each annotation, but I'm trying to get the data passed now. - (void)mapView:(MKMapView *)mapView annotationView:(MKAnnotationView *)view calloutAccessoryControlTapped:(UIControl *)control { // Assuming I call the MapPoint class

shouldPerformSegueWithIdentifier issue

 ̄綄美尐妖づ 提交于 2019-12-01 12:17:22
问题 I tried too much to solve my bellow issue but i am failed.Please help me to solve this issue. I have login view and after validating id and password i am pushing it to next view controller.Please check bellow image. Issue - When Id and Password is correct it's pushing to next view controller but after 2 clicks on login button. Code - ServiceManager.m -(void)initGetAppServiceRequestWithUrl:(NSString *)baseUrl onCompletion: (ServiceCompletionHandler)handler { NSString *fullUrl = [NSString