The app should forward to another view controller based on some data in a database. The database is working fine, but I can’t get the app to forward to the second view controller.
Here’s the code I have in place.
ssSecondViewController *tempView =[[ssSecondViewController alloc] init];
[self.navigationController pushViewController:tempView animated:YES];
I’m not getting any errors but when I run the code the screen forwards to a blank black view?
if you have already your viewController on storyboard then you can assign it by like below code & you must have set identifier to viewControler on storyboard
set your viewController id here,in below image identifier is “MenuViewController”
if it is on .Xib file then
if you just want to add new viewController with programmetically without using already available viewController ,then you have to init it with
initWithFramethen it shows viewControllerssSecondViewController *tempView =[[ssSecondViewController alloc] init];this line just allocates the viewController, it not have any location to draw it.