cocoa touch - Can't set outlets when I push a UIViewController without animating -


i have uinavigationcontroller push uiviewcontrollers onto using pushviewcontroller:animated:. after this, call method on incoming view set of ib outlets. unfortunately, these set when animate view.

so work:

myviewcontroller *newview = [[myviewcontroller alloc] initwithnibname:@"myviewcontroller" bundle:nil]; [self.navigationcontroller pushviewcontroller:newview animated:yes]; [newview updateoutletsforobject:myobject]; 

but won't:

myviewcontroller *newview = [[myviewcontroller alloc] initwithnibname:@"myviewcontroller" bundle:nil]; [self.navigationcontroller pushviewcontroller:newview animated:no]; [newview updateoutletsforobject:myobject]; 

does know why happening? in advance.

it seems me parent view controller shouldn't setting child's outlets. should handling iboutlet connections in -viewdidload of child view controller.


Comments

Popular posts from this blog

php - What is the difference between $_SERVER['PATH_INFO'] and $_SERVER['ORIG_PATH_INFO']? -

fortran - Function return type mismatch -

queue - mq_receive: message too long -