开发者

how to Remove the default navigation bar button

i am using a pushviewcontroller for navigation and i am getting default back button on the navigation bar..... i am trying to hide that default button and make my navigation bar plain.....anybody know how to hide that default nav开发者_StackOverflow中文版igation button on left side of the screen


In the viewDidLoad method of the view controller that is being pushed, you should set the hidesBackButton property of the navigationItem to YES:

- (void)viewDidLoad {
    [super viewDidLoad];

    self.navigationItem.hidesBackButton = YES;
}


Try to set self.title = @""; just before using pushViewcontroller method.


Just like the previous answer: set the hidesBackButton property in the viewDidLoad method. Can also hide the back button in the event of another action after the view is loaded using animation

[self.navigationItem setHidesBackButton:flag animated:flag]
0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜