问题:
I added a new nib file to my project, and tried to load it. 我向项目添加了一个新的nib文件,并尝试加载它。
However, when I click on the toolbar icon that is supposed to take me to the view that I created, I get an NSInternalInconsistencyException
with the message: 但是,当我单击应该将我带到创建的视图的工具栏图标时,我收到一条NSInternalInconsistencyException
消息:
Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: '-[UIViewController _loadViewFromNibNamed:bundle:] loaded the "..." nib but the view outlet was not set.' 由于未捕获的异常'NSInternalInconsistencyException'而终止应用程序,原因:'-[UIViewController _loadViewFromNibNamed:bundle:]加载了“ ...”笔尖,但未设置视图出口。
So I opened up my nib file, and I see for the view that there are no referencing outlets set. 因此,我打开了我的nib文件,并且看到没有设置参考插座的视图。 However, I try to click and drag the circle for "new referencing outlet" to File's Owner, but it won't let me...what do I need to do to get my view to display? 但是,我尝试单击并拖动“新引用出口”的圆圈到File's Owner,但这不会让我...我需要做些什么才能显示我的视图?
解决方案:
参考一: https://stackoom.com/question/JzCx/笔尖已加载-但未设置-查看-出口参考二: https://oldbug.net/q/JzCx/Loaded-nib-but-the-view-outlet-was-not-set
来源:oschina
链接:https://my.oschina.net/u/4438370/blog/4334640