【问题标题】:This class is not key value coding-compliant for the key Picker此类与键 Picker 的键值编码不兼容
【发布时间】:2013-07-23 15:22:03
【问题描述】:

我向我的应用添加了一个视图,我通过一个按钮打开该视图,但找不到我做错了什么。

我三重检查了数据源和委托是否已连接到文件的所有者

*** Terminating app due to uncaught exception 'NSUnknownKeyException', reason: '[<HelpViewController 0xab58980> setValue:forUndefinedKey:]: this class is not key value coding-compliant for the key Picker.'

我的 viewcontroller.h 中的代码

@interface LanguageSelectionViewController : UIViewController {

    IBOutlet UILabel *label;
    IBOutlet UIPickerView *Picker;
    NSArray *PickerData;
}

@property (retain, nonatomic) IBOutlet UIPickerView *Picker;
@property (retain, nonatomic) NSArray *PickerData;
@end

有人有正确方向的解决方案或提示吗?

【问题讨论】:

标签: ios uiviewcontroller


【解决方案1】:

现在使用实用工具栏(右侧的工具栏)单击帮助视图控制器(整个东西,使视图周围有一个蓝色轮廓)单击箭头(最右侧的图标),您应该会看到一个!在其中一个连接上做标记。删除它,它应该可以工作。

【讨论】:

    猜你喜欢
    • 2017-09-27
    • 2015-08-27
    • 2011-03-17
    • 2012-09-24
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2021-12-28
    相关资源
    最近更新 更多