나는 테이블 위에서 머리를 숙일 준비가되었습니다. 아니면 그냥 너무 피곤해. 누구나 눈의 두 번째 세트를 빌려줄 수 있으며 왜 아래의 마지막 if 문에 오류가 발생하는지 알려주시겠습니까?신고하지 않은 식별자 'segue'를 사용하십시오.
덕분에 많은
#import "BAWelcomeViewController.h"
@interface BAWelcomeViewController()
@end
@implementation BAWelcomeViewController
- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
{
self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
if (self) {
// Custom initialization
}
return self;
}
- (void)viewDidLoad
{
[super viewDidLoad];
// Do any additional setup after loading the view.
}
- (void)viewWillAppear:(BOOL)animated {
if (![PFUser currentUser]) {
[self performSegueWithIdentifier:@"Show Login View" sender:self];
return;
}
[self performSegueWithIdentifier:@"Show Main View" sender:self];
}
- (void)didReceiveMemoryWarning
{
[super didReceiveMemoryWarning];
// Dispose of any resources that can be recreated.
}
- (void)performSegueWithIdentifier:(NSString *)identifier sender:(id)sender {
if ([[segue identifier] isequaltostring:@"Show Login View") {
//do something here
}
}
일반적으로 오류 메시지는 잘못된 것에 대한 단서를 제공합니다. 그것 없이는 어떻게 도울 수 있습니까? –
'performSegue ... '메소드 안에'prepareForSegue ...'구현을 넣은 것처럼 보입니다. – jrturton