Re: (newbie) help with combining navigation controller and tab bar controller
Re: (newbie) help with combining navigation controller and tab bar controller
- Subject: Re: (newbie) help with combining navigation controller and tab bar controller
- From: Luke the Hiesterman <email@hidden>
- Date: Fri, 5 Jun 2009 11:20:28 -0700
The short answer is that any view inside your tab bar controller that
you want to have navigation, you set the tab bar controller's
viewController for that view to be an instance of
UINavigationController. The following should help you.
http://developer.apple.com/iphone/library/featuredarticles/ViewControllerPGforiPhoneOS/CombiningToolbarandNavigationControllers/CombiningToolbarandNavigationControllers.html#/
/apple_ref/doc/uid/TP40007457-CH8-SW1
Luke
On Jun 5, 2009, at 10:18 AM, Beth Freeman wrote:
Hi,I'm just learning Cocoa.
I need to build an app that has a navigation controller and a tab bar
controller. Similar to the Huffington Post app: the initial view
for the
tab bar will be a table view, and each row in the table view will
open up a
detail view, and of course the nav bar at the top will allow the
user to go
back to the table view.
What I can't figure out is how to put a navigation controller and a
tab bar
controller into the same view.
I started with a tab bar controller, and got all the views hooked up
just
fine. Then I dragged in a navigation controller, but it creates a
whole
separate window. I want the navigation and the tab bar in the same
window.
I haven't been able to find any examples online that show how to do
this.
I'm attaching a file that is a snapshot of my IB windows for the tab
bat
controller nib (Main Window.xib). You can see how I added a
navigation
controller, and it created a separate window, with a separate view.
I'm
also showing the nib file for the first tab, the topics view (which
corresponds to the TopicsTableViewContoller).
Any help in understanding how to combine navigation and tab bar
controllers
in the same window, or pointers to examples of this would be much
appreciated.
Thank you!
Elisabeth
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden