Hi I keep getting threading errors. I have made a very simple storyboard that has two screens. The first has a button that leads to the second. When I run the app and click the button it crashes with a threading error. I haven't every written any of the code yet has only been working on the storyboards. If you could please advise what is causing it or a way for me to workout what is causing it as I am unable to understand the thread debug errors.
2013-10-10 20:18:54.249 Quote[851:a0b] * Terminating app due to uncaught exception 'NSGenericException', reason: 'Push segues can only be used when the source controller is managed by an instance of UINavigationController.' * First throw call stack: ( 0 CoreFoundation 0x017475e4 exceptionPreprocess + 180 1 libobjc.A.dylib 0x014b68b6 objc_exception_throw + 44 2 UIKit 0x0076c605 -[UIStoryboardPushSegue destinationContainmentContext] + 0 3 UIKit 0x0075c9de -[UIStoryboardSegueTemplate _perform:] + 174 4 UIKit 0x0075ca59 -[UIStoryboardSegueTemplate perform:] + 115 5 libobjc.A.dylib 0x014c8874 -[NSObject performSelector:withObject:withObject:] + 77 6 UIKit 0x0022ac8c -[UIApplication sendAction:to:from:forEvent:] + 108 7 UIKit 0x0022ac18 -[UIApplication sendAction:toTarget:fromSender:forEvent:] + 61 8 UIKit 0x003226d9 -[UIControl sendAction:to:forEvent:] + 66 9 UIKit 0x00322a9c -[UIControl _sendActionsForEvents:withEvent:] + 577 10 UIKit 0x00321d4b -[UIControl touchesEnded:withEvent:] + 641 11 UIKit 0x002680cd -[UIWindow _sendTouchesForEvent:] + 852 12 UIKit 0x00268d34 -[UIWindow sendEvent:] + 1232 13 UIKit 0x0023ca36 -[UIApplication sendEvent:] + 242 14 UIKit 0x00226d9f _UIApplicationHandleEventQueue + 11421 15 CoreFoundation 0x016d08af __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION + 15 16 CoreFoundation 0x016d023b __CFRunLoopDoSources0 + 235 17 CoreFoundation 0x016ed30e __CFRunLoopRun + 910 18 CoreFoundation 0x016ecb33 CFRunLoopRunSpecific + 467 19 CoreFoundation 0x016ec94b CFRunLoopRunInMode + 123 20 GraphicsServices 0x036849d7 GSEventRunModal + 192 21 GraphicsServices 0x036847fe GSEventRun + 104 22 UIKit 0x0022994b UIApplicationMain + 1225 23 Quote 0x0000217d main + 141 24 libdyld.dylib 0x01d6f725 start + 0 25 ??? 0x00000001 0x0 + 1 ) libc++abi.dylib: terminating with uncaught exception of type NSException (lldb)
"'Push segues can only be used when the source controller is managed by an instance of UINavigationController."
That is your problem, Push Segues can only be used with a UINavigationController. To put your first view controller in a navigation controller, click on your first view controller then Editor > Embed > Navigation controller.
User contributions licensed under CC BY-SA 3.0