"this class is not key value coding-compliant for the key ..."问题的解决(转)

一般此问题 都是由interface build与代码中IBOutlet的连接所引起的。

可能是在代码中对iboutlet的名称进行了修改,导致interface build中的连接实效。

如果在该viewcontroller连接的xib文件中没发现错误,

那就很可能是mainWindow.xib文件中存在问题,

本人遇到的问题是在mainWindow.xib的tabbarcontroller的某个tab的viewcontroller设置了loadfrom"**.xib",

但忘了将其class设为对应的viewcontroller类了。

 

 

在MainWindow.xib中,Tab Bar Controller下的ViewController少了一个配置,正确的配置如图:

图1:配置Custom Class

"this class is not key value coding-compliant for the key ..."问题的解决(转)

图2:配置View Controller

"this class is not key value coding-compliant for the key ..."问题的解决(转)

转载于:https://www.cnblogs.com/yaoliang11/archive/2012/11/16/2772668.html