我創建了一個UINavigationController
(作爲初始屏幕),並將它們與我的UITableViewController
(作爲根)連接。popViewController不適用於故事板
接下來,我創建另一個UINavigationController
並與我的UIViewController
連接。在我的UITableViewController
裏面,我連接了我的第一個單元格UINavigationController
(這與我的UIViewController
有關)(Segue - > show)。
當我運行出現在我的表中的項目,當我選擇我的第一排,出現在我的UIViewController。那很棒!
當我在我的UIViewController
back bar按鈕不會出現,在我的情況下,我創建一個左欄按鈕,它將運行一個函數來消除該視圖並返回到我的UITableViewController
,因爲我使用很多代碼:
-(void)back{
NSLog(@"Called");
[self.parentViewController.navigationController popViewControllerAnimated:YES];
}
-(void)back{
NSLog(@"Called");
[self.navigationController popViewControllerAnimated:YES];
}
-(void)back{
NSLog(@"Called");
[self.navigationController popViewControllerAnimated:YES];
}
但他們都不起作用,我的觀點不排除,我該如何解決這個問題?