//获取storyboard 通过bundle 根据storyboard的名字获取我们的storyboard
        let sboard=UIStoryboard(name:"Main", bundle: NSBundle.mainBundle())
        //由storyboard根据视图的id  addplayer  获取我们所要切换的视图
        let view:UIViewController=sboard.instantiateViewControllerWithIdentifier("AddPlayer") as UIViewController
        self.navigationController?.pushViewController(view, animated: true)

 

posted on 2015-05-14 16:55  青年程序猿  阅读(510)  评论(0)    收藏  举报