objective c - Accessing the same view controller in a Storyboard by a subclass -
hullo, create new target project without overcrowding main view controller #ifdef's. thinking of splitting functions weaker superclass , have new target use top one. how configure new target attach top view controller view controller in storyboard instead of bottom 1 in old target?
you have invoke , set view controller manually so:
uistoryboard *storyboard = [uiapplication sharedapplication].keywindow.rootviewcontroller.storyboard; uiviewcontroller *myviewcontroller = [storyboard instantiateviewcontrollerwithidentifier:@"yourviewcontrolleridentifier"]; [[uiapplication sharedapplication].keywindow.rootviewcontroller presentviewcontroller:myviewcontroller animated:yes completion:nil];
Comments
Post a Comment