Navigationcontroller Pushviewcontroller

[Solved] Navigationcontroller Pushviewcontroller | Swift - Code Explorer | yomemimo.com
Question : navigationcontroller.pushviewcontroller

Answered by : frail-flatworm-003mf5w9gyny

//Appdelegate.swift
func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: NSDictionary?) -> Bool { self.window = UIWindow(frame: UIScreen.mainScreen().bounds) let navigat = UINavigationController() let vcw = ViewController(nibName: "ViewController", bundle: nil) // Push the vcw to the navigat navigat.pushViewController(vcw, animated: false) // Set the window’s root view controller self.window!.rootViewController = navigat // Present the window self.window!.makeKeyAndVisible() return true
}
//ViewController.swift
@IBAction func GoToNext(sender : AnyObject)
{ let ViewController2 = ViewController2(nibName: "ViewController2", bundle: nil) self.navigationController.pushViewController(ViewController2, animated: true)
}

Source : https://stackoverflow.com/questions/20742745/navigation-controller-push-view-controller | Last Update : Sun, 23 Feb 20

Answers related to navigationcontroller pushviewcontroller

Code Explorer Popular Question For Swift