I want to 开发者_Go百科show the UIBarButtonItem
and UINavigationItem
through code in the method viewWillAppear
You'll need to give a little more details, but probably you mean something like this:
UIBarButtonItem *btn = [[UIBarButtonItem alloc] initWithTitle: @"Back"
style: UIBarButtonItemStylePlain
target: self
action: @selector(backAction)];
self.navigationItem.leftBarButtonItem = btn;
[btn release];
精彩评论