Segue between two view controllers

前端 未结 3 1853
耶瑟儿~
耶瑟儿~ 2021-02-19 17:02

\"enter

On my storyboard (shown above), I have a ViewController which holds an MKMapView w

相关标签:
3条回答
  • 2021-02-19 17:15

    Simplest way to do this is to select the View controller you want to be the root of your navigation hierarchy and choose

    Editor > Embed In > Navigation Controller
    

    This creates the new navigation controller and hooks up everything up for you.

    0 讨论(0)
  • 2021-02-19 17:34

    check this steps: 1. to click connection between two view controller. 2. click attribute inspector 3. set identifier to "showDetail". 4. save and run.

    0 讨论(0)
  • 2021-02-19 17:37

    You actually have to set your UIViewController as the root controller of a UINavigationController (or pushed through from a view controller w/ a navcontroller). To do that

    • Drag a new navigation controller into your storyboard - it will by default be attached to a tableview controller
    • Delete the tableview controller Right click on the navgiation controller, and connect the "Root View Controller" property to your existing view controller
    • Move the entry point arrow from your view controller to the root view controller
    0 讨论(0)
提交回复
热议问题