我想將數據傳遞給viewController。問題在於它嵌入在navigationController中並以模態方式呈現。如何傳遞到有模式呈現,並嵌入導航控制器通過數據傳遞。 navigationController
func offerNew(sender: UIBarButtonItem) {
let offerVC = self.storyboard?.instantiateViewControllerWithIdentifier("OfferViewController") as UINavigationController
self.presentViewController(offerVC, animated: true, completion: nil);
}
一個的viewController我已經試過這
let offerVC = self.storyboard?.instantiateViewControllerWithIdentifier("offerNavigation") as UINavigationController
let targetVC = offerVC.topViewController as OfferViewController
self.presentViewController(targetVC, animated: true, completion: nil);
應用程序試圖以模態方式呈現主動控制器 – 2014-10-06 21:01:01
您是否提出targetVC或offerVC? – pbasdf 2014-10-06 21:05:14
我正在展示目標VC – 2014-10-06 21:11:24