TableView 与 Tab Bar 的问题?
我创建了一个 tableView,它在单个视图应用程序中工作得很好,但是当我更改了选项卡栏控制器的视图控制器并点击带有表视图的视图选项卡时,我突然得到了这个!出了什么问题?
[Session started at 2010-03-28 15:30:15 +0100.]
2010-03-28 15:30:17.763 LogbookTable[13473:207] *** -[UIViewController tableView:numberOfRowsInSection:]: unrecognized selector sent to instance 0x3b14d10
2010-03-28 15:30:17.765 LogbookTable[13473:207] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** -[UIViewController tableView:numberOfRowsInSection:]: unrecognized selector sent to instance 0x3b14d10'
2010-03-28 15:30:17.766 LogbookTable[13473:207] Stack: (
29303899,
2465178889,
29685819,
29255286,
29107906,
4372518,
4379894,
4378891,
3095430,
3035941,
3077376,
3065931,
55820976,
55820399,
55818438,
55817530,
2739877,
2763572,
2745983,
2773089,
37399897,
29088640,
29084744,
2739733,
2777007,
10496,
10350
)
I created a tableView which worked fine in a single view app but as soon as I changed the view controller for a Tab Bar Controller and tapped the tab for the view with the table view in I suddenly get this! What has gone wrong?
[Session started at 2010-03-28 15:30:15 +0100.]
2010-03-28 15:30:17.763 LogbookTable[13473:207] *** -[UIViewController tableView:numberOfRowsInSection:]: unrecognized selector sent to instance 0x3b14d10
2010-03-28 15:30:17.765 LogbookTable[13473:207] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** -[UIViewController tableView:numberOfRowsInSection:]: unrecognized selector sent to instance 0x3b14d10'
2010-03-28 15:30:17.766 LogbookTable[13473:207] Stack: (
29303899,
2465178889,
29685819,
29255286,
29107906,
4372518,
4379894,
4378891,
3095430,
3035941,
3077376,
3065931,
55820976,
55820399,
55818438,
55817530,
2739877,
2763572,
2745983,
2773089,
37399897,
29088640,
29084744,
2739733,
2777007,
10496,
10350
)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
你在某个地方有一个 UIViewController,它应该是一个 UITableViewController。检查 Interface Builder 中的视图层次结构。
You have an UIViewController somewhere, that should be an UITableViewController. Check your view hierarchy in Interface Builder.