uiviewcontroller - Mixing code-generated view controllers and storyboards -


i've got huge storyboard lots of views defined. created additional view (and it's view controller) in code. how use new, code-generated view in storyboard? make little bit more clear: have 3 view controllers: a, b , c. , c defined via storyboards , work fine. b 1 generated in code. how wire up?

i found quite few answers—but of them did work other way around.

thanks!
–f

you can wire code-generated view controllers code too.

firstly, create subclass of viewcontroller, e.g. , c, have in storyboard can modify view controllers storyboard code.

then, use navigationcontroller pushviewcontroller:animated: method push code-generated view controller, e.g. b or view controller methods, e.g. or c, presentviewcontroller:animated:completion: present view controller modally.

if want push view controllers storyboard within code-generated view controllers, can use storyboard method instantiateviewcontrollerwithidentifier:. remember set storyboard id of view controllers.


Comments

Popular posts from this blog

user interface - Python attempting to create a simple gui, getting "AttributeError: 'MainMenu' object has no attribute 'intro_screen'" -

java - Multi-Label Document Classification -

php - Dynamic url re-writing using htaccess -