I have a tab bar controller with 4 views controller, and have this tab bar controller in a navigation controller.
I want to display a UIBarButtonItem for just one specific view controller of the tab bar controller.
I tried to use the following
if (tabBarController.selectedViewController == customTourViewController)
{
[tabBarController.navigationItem setRightBarButtonItem:done];
}
But the button doesn't show up.
If I put every view controller in a navigation controller, then the button shows up for only that view, but I end up having 2 navigation bars.
Is there any way I can implement the first solution? Thanks.