I wanted to be able to enter a view controller only if an entered password is correct. i used the following code -
if(([input isEqual:@"12"]))
{
NSLog(@"change view controller");
NSString * storyboardName = @"Main";
UIStoryboard *storyboard = [UIStoryboard storyboardWithName:storyboardName bundle: nil];
UIViewController * vc = [storyboard instantiateViewControllerWithIdentifier:@"secondViewController"];
[self presentViewController:vc animated:YES completion:nil];
}
but when i enter , Xcode gave me a sigbrt error, so i added an all exception breakpoint, but it goes to main.m and says 'thread 1:break point 1.1'.
thank you for reading and if you know the answer please answer