开发者

how can i display a image on button which is presented on UINavigationController iphone?

ho开发者_StackOverflow中文版w can i display a image on button which is presented on UINavigationController iphone ?


if you mean the back button that is displaying on the Navigation Bar you can do

UIBarButtonItem *barBtnItem = [[UIBarButtonItem alloc]initWithTitle:@"title" style:UIBarButtonItemStyleBordered target:nil action:nil];
barBtnItem.image = [UIImage imageNamed:@"image.png"];
self.navigationItem.backBarButtonItem=barBtnItem;
[barBtnItem release];

Put this code in the Previous page's viewDidLoad method or anywhere else before

[self.navigationController pushViewController:viewController animated:YES];

this line

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜