解决:Terminating app due to uncaught exception 'NSInvalidUnarchiveOperationException', reason: 'Could

打开新页面就崩溃,连机调试看到错误:

Terminating app due to uncaught exception 'NSInvalidUnarchiveOperationException', reason: 'Could not instantiate class named NSLayoutConstraint'


网上查了下解决方法:

By default, when you create a new iOS project in Xcode 4.5, your storyboard or XIB is set to use Autolayout, which is a new feature in iOS 6.0. The NSLayoutConstraint class is part of the Autolayout system, and it doesn't exist in older versions of iOS.

If you want to deploy your app to an older version of iOS, you need to change your storyboard or XIB tonot use Autolayout. It's a checkbox in the File Inspector:

解决:Terminating app due to uncaught exception 'NSInvalidUnarchiveOperationException', reason: 'Could_第1张图片



参考:http://stackoverflow.com/questions/13201586/nsinvalidunarchiveoperationexception-could-not-instantiate-class-named-nslayout

你可能感兴趣的:(解决:Terminating app due to uncaught exception 'NSInvalidUnarchiveOperationException', reason: 'Could)