Segue无法在iOS中的视图控制器中执行

时间:2014-06-10 06:12:36

标签: ios iphone ipad

Segue无法在视图控制器中执行,

我试过了:

UIViewController *toViewController = [self.storyboard instantiateViewControllerWithIdentifier:@"menu"];
 [self.navigationController pushViewController:toViewController animated:YES];

[self performSegueWithIdentifier: @"sidebar_segue" sender:self];

两者但它给了我一个错误,如

  -[__NSCFNumber length]: unrecognized selector sent to instance 0xb89f1b0
2014-06-10 13:05:11.328 naanking[1720:60b] *** Terminating app due to uncaught  exception 'NSInvalidArgumentException', reason: '-[__NSCFNumber length]: unrecognized  selector sent to instance 0xb89f1b0'
*** First throw call stack:
(
0   CoreFoundation                      0x028431e4 __exceptionPreprocess + 180
1   libobjc.A.dylib                     0x01e548e5 objc_exception_throw + 44
2   CoreFoundation                      0x028e0243 -[NSObject(NSObject) doesNotRecognizeSelector:] + 275
3   CoreFoundation                      0x0283350b ___forwarding___ + 1019
4   CoreFoundation                      0x028330ee _CF_forwarding_prep_0 + 14
5   UIKit                               0x00ac4463 -[UILabel _shadow] + 45
6   UIKit                               0x00ac58c2 -[UILabel drawTextInRect:] + 70
7   UIKit                               0x00ac7dfc -[UILabel drawRect:] + 98
8   UIKit                               0x00976453 -[UIView(CALayerDelegate) drawLayer:inContext:] + 504
9   QuartzCore                          0x004a7f39 -[CALayer drawInContext:] + 123
10  QuartzCore                          0x004a7e6a _ZL16backing_callbackP9CGContextPv + 96
11  QuartzCore                          0x003964fc CABackingStoreUpdate_ + 2656
12  QuartzCore                          0x004a7e02 ___ZN2CA5Layer8display_Ev_block_invoke + 93
13  QuartzCore                          0x004dc2d7 x_blame_allocations + 15
14  QuartzCore                          0x004a7c6d _ZN2CA5Layer8display_Ev + 1519
15  QuartzCore                          0x004a7eb9 -[CALayer _display] + 33
16  QuartzCore                          0x004a7676 _ZN2CA5Layer7displayEv + 144
17  QuartzCore                          0x004a7e93 -[CALayer display] + 33
18  QuartzCore                          0x0049c043 _ZN2CA5Layer17display_if_neededEPNS_11TransactionE + 323
19  QuartzCore                          0x0049c0bc _ZN2CA5Layer28layout_and_display_if_neededEPNS_11TransactionE + 38
20  QuartzCore                          0x004027fa _ZN2CA7Context18commit_transactionEPNS_11TransactionE + 294
21  QuartzCore                          0x00403b85 _ZN2CA11Transaction6commitEv + 393
22  QuartzCore                          0x004c15b0 +[CATransaction flush] + 52
23  UIKit                               0x009059bb _UIApplicationHandleEventQueue + 13095
24  CoreFoundation                      0x027cc77f __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 15
25  CoreFoundation                      0x027cc10b __CFRunLoopDoSources0 + 235
26  CoreFoundation                      0x027e91ae __CFRunLoopRun + 910
27  CoreFoundation                      0x027e89d3 CFRunLoopRunSpecific + 467
28  CoreFoundation                      0x027e87eb CFRunLoopRunInMode + 123
29  GraphicsServices                    0x0276c5ee GSEventRunModal + 192
30  GraphicsServices                    0x0276c42b GSEventRun + 104
31  UIKit                               0x00907f9b UIApplicationMain + 1225
32  naanking                            0x0001cccd main + 141
33  naanking                            0x000029d5 start + 53
)
libc++abi.dylib: terminating with uncaught exception of type NSException

..................................
像这样。 你能给我一个如何解决它的建议吗?

0 个答案:

没有答案