本文介绍了以NSException类型(xcode 6)的未捕获异常终止的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

由于未捕获的异常而终止应用程序:

Terminating app due to uncaught exception:

'NSInternalInconsistencyException', reason: '-[UIViewController _loadViewFromNibNamed:bundle:] loaded the "ViewController"笔尖,但未设置视图出口.

'NSInternalInconsistencyException', reason: '-[UIViewController _loadViewFromNibNamed:bundle:] loaded the "ViewController" nib but the view outlet was not set.

我在xcode 6中收到此错误.我知道如何在xcode 5或更低版本中设置视图出口(转到连接检查器,将出口单选按钮拖动到文件的所有者,然后弹出视图,然后单击视图来设置出口),但视图弹出未在xcode 6(测试版)中出现.是xcode 6错误还是设置插座的方式不同.有人可以帮忙吗?

I am getting this error in xcode 6. I know how to set view outlet in xcode 5 or below version (go to connection inspector drag outlet radio button to file's Owner then it pop with a view and then click on view sets the outlet) but view popup is not comming in xcode 6 (beta). Is it a xcode 6 bug or it has different way to set an outlet.Can anyone help please?

推荐答案

这意味着您具有视图控制器,但尚未设置view出口.在界面构建器中,右键单击视图控制器,然后将显示插座和操作弹出窗口.找到视图出口,然后将其拖到视图列表中的最高视图.

It means you have a view controller, but you have not set the view outlet. In interface builder, right click on the view controller, and outlet and action popup will appear. Find the view outlet, and drag it to the topmost view in the views list.

这篇关于以NSException类型(xcode 6)的未捕获异常终止的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-14 17:53