开发者

Alertview click to UITableviewcontroller

am new to iphone programming. I have a viewcontoller with an alertview in it. When the ok button on alertview is clicked it takes 开发者_Go百科to another UITableviewcontroller. I am able to get my cells with objects in it. but am unable to get the navigation bar on top. please tell me y is it so?

thanks viki


-(void)alertView:(UIAlertView *) alertview clickedButtonAtIndex:(NSInteger)buttonIndex {

    if(buttonIndex == 1){
        Accidenthelpercall* help = [[Accidenthelpercall alloc]initWithNibName:@"Accidenthelpercall" bundle:nil];
        [self presentModalViewController:help animated:YES];
        [help setTitle:@"Accident Helper"];
        [help release];
    }

    if(buttonIndex == 2)
        {               
            Accidentdamagecar* damagecar = [[Accidentdamagecar alloc]initWithNibName:@"Accidentdamagecar" bundle:nil];
            [[self navigationController] pushViewController:damagecar animated:YES];
                    [damagecar setTitle: @"Car Damage"];
                    [damagecar release];

        }
}
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜