0

这是我的代码:

UINavigationController *navigationController = [[UINavigationController alloc] initWithRootViewController:vc];
UIBarButtonItem *anotherButton = [[UIBarButtonItem alloc] initWithTitle:@"RETURN" style:UIBarButtonItemStylePlain target:self action:@selector(refreshPropertyList:)];
navigationController.navigationItem.rightBarButtonItem = anotherButton;
[anotherButton release];       
[IpadAppDelegate.stackController presentModalViewController:navigationController animated:YES];

在此处输入图像描述

4

1 回答 1

0

我找出原因:

需要改变navigationController.navigationItem.rightBarButtonItem = anotherButton;

到:self.navigationItem.rightBarButtonItem = anotherButton;

于 2013-01-16T03:28:25.850 回答