i created an iPad application, in which navigation is not working,
for example on click of cell of tableView, it should navigate to new view.
code snippet for the same:
appDelegate.m
-(void)applicationDidFinishLaunching:(UIApplication *)application {
UINavigationController *navController = [[UINavigationController alloc] initWithRootViewController:viewController];
[window addSubview:navController.view];
[window addSubview:viewController.view];
[window makeKeyAndVisible];
}
After this i am creating UIViewControllerSubclass, crollnext.
Inside this file i am performing some operation,and finally in my mainViewController
-(void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
crollnext *crollController =[[crollnext alloc]initWithNibName:@"crollView" bundle:nil];
[self.navigationController pushViewController:crollController animated:YES];
[crollController changeProductText:[tableData objectAtIndex:indexPath.row]];
}
}
Have i made any mistake in code ?
here is a screenshot

Thanks In Advance
Notice that you are adding your viewController.view on top of the window’s stack of views, after adding your navController.view. What you should do is something like this:
The navController, for itself its nothing. You need to fill it with something (in this case your viewController as the rootViewController.