正如您所看到的,我正在尝试从Photo Action View Controller到设置视图控制器(UITableViewController
)的performSegue
。PerformSegue无法正确执行
所以我从PhotoActionViewController
直接(不使用按钮等),因为我想,当用户从显示AlertView
一个选项水龙头来执行此SEGUE执行。一切工作都像魅力,直到我为SettingsViewController
设置类。赛格表演但我看不到任何UITableViewCell
。我怎么能得到这个工作形式?
这里是我的代码:
- (IBAction)imageViewTapped:(UITapGestureRecognizer *)sender
{
BlockAlertView *alert = [BlockAlertView alertWithTitle:@"New Photo" message:@"Decide what you would like to do with this photo"];
[alert addButtonWithTitle:@"Create New Project" block:^{
// Pushing to New Project Settings Controller
[self performSegueWithIdentifier:@"NPSSegue" sender:self];
}];
[alert addButtonWithTitle:@"Add To Existing Project" block:^{
NSLog(@"Add to existing");
}];
[alert setCancelButtonWithTitle:@"Cancel" block:nil];
[alert show];
}
我没有张贴prepareForSegue
,因为它是空的这一刻,我不知道如果有什么应该在那里。
首先。不要将'self'传递给'performSegueWithIdentifier'只是传递'nil'。现在看其余的... – Fogmeister
你可以显示'SettingsViewController'的代码。 – Fogmeister
没有什么!只是从'UITableViewController'继承的新类如此,例如:'numberOfSectionsInTableView:'等 – cojoj