加载了笔尖,但没有得到UITableView异常 [英] Loaded the nib but didn't get a UITableView Exception
问题描述
我正在尝试使用 ECSlidingViewController加载 uitableview
方法。
I'm trying to load a uitableview
using ECSlidingViewController methods.
当我调用此代码时:
UIStoryboard* sb = [UIStoryboard storyboardWithName:@"MainStoryboard_iPhone"
bundle:nil];
UITableViewController* page = [sb instantiateViewControllerWithIdentifier:@"tableViewPage"];
CGRect frame = self.slidingViewController.topViewController.view.frame;
self.slidingViewController.topViewController = page;
self.slidingViewController.topViewController.view.frame = frame;
[self.slidingViewController resetTopView];
而tableViewPage是一个tableView控制器,而不是带有表的视图。它给了我:
while "tableViewPage" is a tableView Controller, not a view with a table. It gives me:
[UITableViewController loadView]加载
Bzc-w8-vsI-view-gnu-XH-Eb0 nib但没有获得UITableView。
[UITableViewController loadView] loaded the "Bzc-w8-vsI-view-gnu-XH-Eb0" nib but didn't get a UITableView.'
我试图制作一个类似 topViewController的方法
仅适用于 uitableviewcontroller
而不是 uiviewcontroller
...但我失败了。我错过了什么?
I tried to made a method like topViewController
just for uitableviewcontroller
instead of uiviewcontroller
... but I failed. What did I miss?
推荐答案
我认为它试图告诉你你有一个 UITableViewController 您的故事板中的code>但与该控制器关联的顶级视图不是
UITableView
。
I think it's trying to tell you that you have a UITableViewController
in your storyboard but the top-level view associated with that controller is not a UITableView
.
这篇关于加载了笔尖,但没有得到UITableView异常的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!