ios - Assertion failure in -[UINib initWithNibName:directory:bundle:] -
i error below message when touched uitextfield in view controller.
msg:
*** assertion failure in -[uinib initwithnibname:directory:bundle:], /sourcecache/uikit/uikit-2380.17/uinib.m:96 2013-08-26 15:58:43.547 xpointer[1023:907] *** terminating app due uncaught exception 'nsinternalinconsistencyexception', reason: 'invalid parameter not satisfying: (name != nil) && ([name length] > 0)'
this error show , crash everywhere(all view controller).
i had same crash, funny, forgot pass nib name.
bad code:
myviewcontroller *vc = [[myviewcontroller alloc] initwithnibname:@"" bundle:nil]; [self.navigationcontroller pushviewcontroller:vc animated:yes]; [vc release]
good code:
myviewcontroller *vc = [[myviewcontroller alloc] initwithnibname:@"myviewcontroller" bundle:nil]; [self.navigationcontroller pushviewcontroller:vc animated:yes]; [vc release]
Comments
Post a Comment