10
votes

My app is working very fine on iPhone and Simulator with iOS 6, but when i try to run on iPhone/Simulator with iOS 5 the app crashes

The error is:

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

I'm not using Autolayout on Interface Builder Document.

Could anyone help me?

Autolayout is not checked

2
How can i make it? Yes I'm of Hungarian origins, you too?Nathan Hegedus

2 Answers

35
votes

make sure you have unselected use autolayout in interfacebuild

enter image description here

12
votes

You've been burned. NSLayoutConstraint only exists on iOS 6. You have to check to see if it's there, and if it's not, you have to do something else.