IOS va a la vista específica desde el controlador de la barra de pestañas desde otra vista

I have a view with 3 buttons and a tabbar controller that contains 3 views. I am using the storyboard. I want go from my view to a specific view from the tabbar controller. When I create a segway to the destination view, the tabbar is not included.

The only way I find out is to create a segway to the tabbar controller itself, but then by default the first view is been shown.

Gracias de antemano!

preguntado el 09 de marzo de 12 a las 15:03

1 Respuestas

Yess!! I got the solution. Do the following:

In you're .h file:

@property (strong, nonatomic) UITabBarController *tabController;

In you're .m file:

@synthesize tabController;

tabController = [self.storyboard instantiateViewControllerWithIdentifier:@"tabbar"];

The selected index is the tab you want to go

tabController.selectedIndex = 1;

[[self navigationController] pushViewController:tabController animated:YES];

respondido 10 mar '12, 14:03

No es la respuesta que estás buscando? Examinar otras preguntas etiquetadas or haz tu propia pregunta.