Implement the method - (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
and write SecondViewControllerNVC2 *objectNVC2
in .h file
it's look like following
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
if (!objectNVC2) {
objectNVC2 = [[SecondViewControllerNVC2 alloc] initWithNibName:@"SecondViewControllerNVC2" bundle:nil];
UIBarButtonItem *backBarButtonItem = [[UIBarButtonItem alloc] initWithTitle:@"Back" style:UIBarButtonItemStylePlain target:nil action:nil];
self.navigationItem.backBarButtonItem = backBarButtonItem;
[backBarButtonItem release];
[self.navigationController pushViewController:objectNVC2 animated:YES];
}