I have a UIViewController
called FriendsViewController
inside a UINavigationController
. And a second UIViewController
called FriendsDetailedViewController
. When navigating from the first view controller to the second, I want to programmatically press the Back
button when needed. How to do this?
Simply use
[self.navigationController popViewControllerAnimated:YES]
from FriendsDetailedViewController. Your view will be popped out i.e. the behavior of back button