应用程序委托中的 NSUnknownKeyException 错误 [英] NSUnknownKeyException error in app delegate

查看:23
本文介绍了应用程序委托中的 NSUnknownKeyException 错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的应用程序在我曾经使用过标签和文本字段的应用程序委托的每个屏幕上都崩溃了.删除标签后,应用程序运行良好,但再次连接到 swift 文件时再次崩溃.

My app is crashing on every screen at app delegate where ever I have used label and textfields. When the tags are removed app is working fine but is crashing again when connected to swift file again.

推荐答案

如果您遇到此类错误

STEP 1:Go XIB or if use STORYBOARD go STORYBOARD
STEP 2:Click View Controller
STEP 3:Again Give connection properly(Fill the circle)
STEP 4:Also check whether it is for button action or outlet property

非常重要:右键单击文件的所有者(黄色),然后单击连接检查器"(右上箭头),一次查看所有出口.寻找 !s 表示缺少插座.删除它.现在它可以工作了.

这篇关于应用程序委托中的 NSUnknownKeyException 错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆