如何在iphone中获得这种后退按钮
我是 Objective-C 的新手,谁能告诉我如何
获得这种
在导航栏上 后退按钮,单击它应该导航到上一页。
I am new to Objective-C, can anyone tell me how to get this kind
of back button on the navigation bar, on click of that it should navigate to previous page.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
这是基于导航的应用程序的默认后退按钮样式。
您可以在创建新应用程序时通过选择基于导航的应用程序来使用它。
创建应用程序后,您必须设置视图的标题。
该视图标题将是后退按钮的标题。
如果您没有上一视图的标题,后退按钮将不会自动出现。
你可以像这样推送视图:
在这种情况下,navigationController已经由Xcode创建,你必须准备settingViewController(.h,.m,.xib)。
It is default back button style of Navigation-based application.
You can use it by selecting Navigation-based application when creating new application.
After created the application, you must set title of the view.
That view title will be the title of back button.
If you have no title of previous view, the back button will not appear automatically.
You can push view like this:
In this case, navigationController is already created by Xcode and you must prepare settingViewController(.h, .m, .xib).
试试这个..
[self.navigationController popViewControllerAnimated:YES];
它将返回到上一页..
Try this ..
[self.navigationController popViewControllerAnimated:YES];
it will get back to previous page ..
你可以按照 BoltClock 所说的去做。
您还可以设置此标题,
转到您定义导航控制器的类
,然后转到 xib 文件。
在您的导航控制器中,有一个导航项选择选项,
现在转到属性检查器并写下您希望使用的标题
祝您好运
You can do as BoltClock had said.
and you can also set this title
go to the class where you have defined your navigation controller
and then go to the xib file..
in that in your navigation controller there is a option of navigation item select that
now go to attribute inspector and write down the title you wish to use
best of luck