Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to do tabBar.title != navBar.title?

Tags:

iphone

I have tab bar, and navigation bar in it. In navigation bar I have table view. The problem is, when I set the title to the tab bar in IB, and next set the title in table view, tab bar title is changing to title from table view, and I have the same title in navigation bar and tab bar, but I want have different titles there.

How to set tab bar title to be different then in van bar?

like image 910
Andrew Avatar asked Jul 22 '10 09:07

Andrew


2 Answers

Try this:

self.navigationController.navigationBar.topItem.title = @"Your Title";

This link also has a similar but different solution: self.title sets navigationController and tabBarItem's title? Why?

like image 80
Brad Avatar answered Nov 03 '22 07:11

Brad


self.navigationItem.title = "Your title"
like image 25
MobileMon Avatar answered Nov 03 '22 06:11

MobileMon