[UIView numberOfComponentsInPickerView:]: unrecognized selector sent to instance

今天写Picker View的小Demo竟然莫名其妙报错了,折腾了半天也没搞明白为什么。后来才知道是Picker View的dataSource 和 delegate 连接错了,应该在xib中连接File's Owner而不是View……

[UIView numberOfComponentsInPickerView:]: unrecognized selector sent to instance_第1张图片


你可能感兴趣的:([UIView numberOfComponentsInPickerView:]: unrecognized selector sent to instance)