0

이제 응용 프로그램은 UINavigationController로 구성되어 있습니다. 그러면 단추를 통해 일반 UIViewController로 전달되고, presentModalViewController를 사용하여 다른 UIViewController를 탐색 막대없이로드합니다.)presentModalViewController는 IOS 5.1에서 UINavigationController 내부에서 sigabrt를 발생시킵니다.

만약 내가 IOS 6.1 시뮬레이터에서 프로그램을 실행하려고하면, 이것은 완벽하게 정상적으로 작동합니다. 그러나 IOS 5.1 시뮬레이터에서 대신 실행하려고하면 presentModalViewController를 호출 할 때 sigabrt 오류가 발생합니다. 이 코드는 UINavigationController를 도입하기 전에 작동했지만 지금은 무엇이 오류를 일으키는 지 전혀 알지 못합니다.

아마 관련 세부 사항 :

은 UINavigationController 및 스토리 보드의 사용을 통해 최초의 UIViewController 작업 모두. 그러나, 두 번째 UIViewController (내가 전달 해요) .xib 파일을 통해로드를 사용하고 있습니다.

실제 패스 코드는 다음과 같습니다.

2013-05-17 13:38:49.934 Practice Solutions[4372:15203] *** Terminating app due to uncaught exception 'NSInvalidUnarchiveOperationException', reason: 'Could not instantiate class named NSLayoutConstraint' 
*** First throw call stack: 
(0x1627022 0xf9fcd6 0x15cfa48 0x15cf9b9 0x4234a3 0x42367b 0x423383 0x32316d 0x1c91fc 0x1c9779 0x1c999b 0x1d29bc 0x1cd818 0x3e9565 0x1d0857 0x1d09bc 0x1d09fc 0x4d7e 0x1628e99 0x10514e 0x1050e6 0x1abade 0x1abfa7 0x1ab266 0x12a3c0 0x12a5e6 0x110dc4 0x104634 0x17baef5 0x15fb195 0x155fff2 0x155e8da 0x155dd84 0x155dc9b 0x17b97d8 0x17b988a 0x102626 0x274d 0x2675) 
terminate called throwing an exception(lldb) 

사람이 도움을 수 있다면

, 즉 주시면 감사하겠습니다 :

AllViewController* controller = [[AllViewController alloc] initWithNibName:[NSString stringWithFormat:@"AllViewController"] bundle:nil]; 
    controller.delegate = self; 

    //And now for the swap 
    controller.modalTransitionStyle = UIModalTransitionStyleFlipHorizontal; 
    [self presentModalViewController:controller animated:YES]; 

는 그리고 오류 콘솔의 출력이됩니다.

+0

FYI,이 비트의 코드 'initWithNibName : [NSString stringWithFormat : @ "AllViewController"] 번들 : nil]''initWithNibName : @ "AllViewController"번들 : nil]'' – Justin

+0

'으로 줄일 수 있습니다. 새로운 질문을 게시하기 전에 오류의 핵심 요소를 검색하십시오. – rmaddy

답변

1

Interface Builder에서 사용하는 제약 조건이며 iOS 6에서만 작동하므로 IB에서 해당 제약 조건을 해제해야합니다.

관련 문제