tags:

views:

19

answers:

1

Hey guys. I have a problem with presenting and dismissing a modalViewController that contains a tabBarView controller (with two viewControllers).

I have no problem in presenting and dismissing the modal, but I have a navbar setup at the top of each view controller with a done button that will dismiss the modal and return the user back to the main view. The problem is that when the user taps the button to bring up the modal, it brings up the viewController that released the modal. I would prefer it to bring up the first viewController (the one furthest left on the tabBar).

I know it's really vague, but any ideas?

Thank you!

-Kagi

A: 

Try putting tabBarController.selectedIndex = 0; in there somewhere before the modal controller is presented.

Nimrod
Perfect!! Thank you very much! It took some fiddling around with, but you totally set me in the right direction!
YuKagi