iOS 5 Storyboard:NavigationViewController 到 TabbarController - 不起作用,为什么?
我正在使用带有 Storyboard 的 iOS5,我的场景如下所示:
NavigationCOntroller ->(Nav view 1) TableViewController -> TabBarController ->(Tab1)TableViewController 同样,我在 TabBarController 下有更多选项卡。
现在,当用户单击 TableViewCOntroller 中的任何行时,我会转到 Tab1,并且在 PerformingSegue 之前,我想将一些数据发送到我的 Tab1(TableViewController),如下所示
MyTableVController *tvc = segue.destinationViewController;
tvc.selectedObject = currentObject;
[UITabBarController setSelectedObject:]: 无法识别的选择器发送到实例 0x68c9450
现在为什么它假设 ' MyTableVController' 是一个 UITabBarController 并正在搜索 setSelectedObject 方法???
在这种情况下如何将数据传递到我的 TableViewCOntroller ?
谢谢。
I am using iOS5 with Storyboard and my scenes are like this :
NavigationCOntroller ->(Nav view 1) TableViewController -> TabBarController ->(Tab1)TableViewController
and similarly I more tabs under my TabBarController.
Now I go to Tab1 when user clicks on any row in my TableViewCOntroller and before PerformingSegue I want to send some data to my Tab1(TableViewController) like this
MyTableVController *tvc = segue.destinationViewController;
tvc.selectedObject = currentObject;
[UITabBarController setSelectedObject:]: unrecognized selector sent to instance 0x68c9450
Now why is it assuming that 'MyTableVController' is a UITabBarController and searching for setSelectedObject method ???
And how can I pass data to my TableViewCOntroller in this scenario ?
Thanks.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
好的,我已经找到了我的问题的解决方案,我确实喜欢这样
,这就是您如何拥有所需的视图控制器并将数据传递给它的方式。
OK I have found solution to my problem , I did like this
And thats how you have your required viewcontroller and pass data to it.