Daniel Rahamim Daniel Rahamim - 1 year ago 106
iOS Question

IOS perform segue from tab bar item

I have a Tab bar controller with 2 items. The first item is a VC which contains a table view. Clicking on a cell, performs a segue to some other view controller (not an item on the tab bar controller).

The problem is that it removes the tab bar when segue completes.
How can I just replace the item 1 with other VC and still keep the tab bar in the bottom?

My Storyboard

Answer Source

You need to embed your Item1VC to NavigationController so that when you push from ItemVCto MoviesViewController it will not remove the tabbar, if you doesn't embed the NavigationController then it will push from the main ViewControllerin your case it is TabbarController so that you are not able to see the tabbar.