开发者

Going from a Modal View to another ViewController

开发者 https://www.devze.com 2023-02-03 03:29 出处:网络
How do I go from a Modal ViewController开发者_高级运维 under a Tab #1\'s ViewController to a ViewController under Tab #3 when the user hits the done button in the Modal VC?

How do I go from a Modal ViewController开发者_高级运维 under a Tab #1's ViewController to a ViewController under Tab #3 when the user hits the done button in the Modal VC?

I know how to pop the Modal VC and return the user to the ViewController that instantiated it but then the user still has to manually navigate himself to Tab #3.

Thanks in advance,

Hiren.


If you navigate from a page to another page then this will be done in same tab if you want to change tab.

then you can use [yourAppObj.tabBarController setSelectedIndex:2]; from a page of 1 tab page to view third tab view.

make object for app delegate class for this import app delegate class then

yourAppDelegate *yourAppObj=(yourAppDelegate *)[[UIApplication sharedApplication] delegate];

then you can use above line in you view.

0

精彩评论

暂无评论...
验证码 换一张
取 消