Call pushview from a subview

Posted by slaapwagen on Stack Overflow See other posts from Stack Overflow or by slaapwagen
Published on 2010-04-04T11:47:55Z Indexed on 2010/04/04 11:53 UTC
Read the original article Hit count: 461

Hello everyone,

Here is the thing. I currently have a tabBar controller, with several navigation controllers in it. Just like this :

http://tof.canardpc.com/view/d27d1361-c81b-43a0-9b5b-abb13d78e422.jpg

In my first navigation controller, i have a view controller called NewsViewsController. Here is its nib (see picture).

My goal is to show/hide the subviews (with tableview inside) according to the position of the segmented control. This way, I can have two separates viewControllers for each tableview. This is actually working. And here is the result (see picture).

My problem is the following one. When i try to click on a cell, the pushview doesn't work. Indeed my self.navigationController is null. How can i push my detail view using the parent navigation controller ?

Is the architecture of my application wrong ? Thank you =)

© Stack Overflow or respective owner

Related posts about uinavigationcontroller

Related posts about pushviewcontroller