MHCustomTabBarController icon indicating copy to clipboard operation
MHCustomTabBarController copied to clipboard

select tab manually from any view

Open farazhaider88 opened this issue 9 years ago • 2 comments

In a custom tab bar embed view controller i have a button. i want to show a another tab with its action. how can i do that?

farazhaider88 avatar Oct 08 '15 07:10 farazhaider88

Can you create an example project showing the Storyboard setup, the button etc.? I think with this information it would be easier to help.

Best regards, Martin

hartlco avatar Oct 27 '15 09:10 hartlco

hey mhaddl, i fixed this by using this but i dont know is this a correct approach

  • (IBAction)viewMoreTweetsClicked:(id)sender { MHCustomTabBarController* controller = (MHCustomTabBarController*)self.parentViewController.parentViewController; controller.selectedIndex = 2; [controller performSegueWithIdentifier:@"viewController2" sender:[controller.buttons objectAtIndex:1]];

}

farazhaider88 avatar Oct 27 '15 11:10 farazhaider88