iOS运行时异常

时间:2013-01-22 03:49:03

标签: ios uiviewcontroller crash storyboard

我正在使用storyboard和ARC创建一个iOS 6应用程序。 但是我收到了这个运行时异常:

Terminating app due to uncaught exception 'NSUnknownKeyException', reason: '[<ViewController 0x71b4c00> setValue:forUndefinedKey:]: this class is not key value coding-compliant for the key switchButton.'
*** First throw call stack:
(0x1c8e012 0x10cbe7e 0x1d16fb1 0xb78711 0xaf9ec8 0xaf99b7 0xb24428 0x2300cc 0x10df663 0x1c8945a 0x22ebcf 0xf3e37 0xf4418 0xf4648 0xf4882 0x43a25 0x43dbf 0x43f55 0x4cf67 0x10fcc 0x11fab 0x23315 0x2424b 0x15cf8 0x1be9df9 0x1be9ad0 0x1c03bf5 0x1c03962 0x1c34bb6 0x1c33f44 0x1c33e1b 0x117da 0x1365c 0x25dd 0x2505)
libc++abi.dylib: terminate called throwing an exception
(lldb) 

在有'switchButton'之前,我已经从GUI中删除了它,但它指向了它。我也进行了项目清理。

1 个答案:

答案 0 :(得分:0)

已通过从Outlets palet中删除switchButton来修复。