开发者

Alertview click to UITableviewcontroller

开发者 https://www.devze.com 2022-12-21 19:41 出处:网络
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 cel

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

精彩评论

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