views:

189

answers:

1

I'm using the code extracted from the URL http://www.iphonemusings.com/2009/01/iphone-programming-tutorial-creating.html to show initial screen with tab bar and having table view in both the tabs. It is displaying the text in cells as well after taking necessary changes in table view delegate. Now I want to show a view on click of table view. I'm using following code.

- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
    Latest* evnt = (Latest*)[latestArray objectAtIndex:indexPath.row];
    NSString* url = [evnt URLLink];
    DetailedView* dv = [[DetailedView alloc] init];
        [dv.label setText=@"Testing label"];
    [self.navigationController pushViewController:dv animated:YES];
    [dv release];
}

But it is not displaying any text. Can some one help me by pointing what mistake is in my code???

A: 

Does this compile? [dv.label setText=@"Testing label"]; is not Objective-C. It should read:

[dv.label setText:@"Testing label"];
Jeff Kelley