How to remove all views from navigation stack?
I have around 25 views in a navigation based 开发者_StackOverflow社区app. From the 25th view I want to come back to home screen. How do I remove all the views from navigation stack? Do I have to check for each view is not nil and remove from stack?
Please help. Thanks in advance.
[self.navigationController popToRootViewControllerAnimated:FALSE];
You can use popToRootViewController using this method: popToRootViewControllerAnimated:
Refer: popToRootViewController
精彩评论