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

Popular posts from this blog

c++ - Linked List error when inserting for the last time -

java - activate/deactivate sonar maven plugin by profile? -

tsql - Pivot with Temp Table (definition for column must include data type) -- SQL Server 2008 -