iPhone SDK: PushViewController not working
- by iPhone Developer
I am trying to create a basic navigation application with a header and detail screen. My problem is the detail screen is not working. The code below is for the opening the detail view and placing it on the nav stack. My problem is the detail screen is not being pushed and I'm not sure why? I have verified the method below is firing.
Any ptr or links to examples appreciated.
//this opens up a detail view
-(void) tableView:(UITableView *)tb didSelectRowAtIndexPath:(NSIndexPath *)indexPath
{
NSLog(@"DETAIL VIEW.....");
NSInteger index = [indexPath indexAtPosition:1];
Retailer *retailer = [self retailerAtIndex:index];
if(retailer)
{
NSLog(@"DETAIL VIEW helelelelekjekljklerj.....");
Membership * newMem = [[Membership alloc] init];
[newMem setIssuerId:[retailer retailerId]];
MembershipViewController * mvc = [[MembershipViewController alloc] initWithNibName:nil bundle:nil];
[mvc setSubject:newMem];
RootAppDelegate *appDelegate = (RootAppDelegate *)[[UIApplication sharedApplication] delegate];
[appDelegate.landingRetailersNavController pushViewController:mvc animated:YES];
[mvc release];
[newMem release];
}