Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Recursive Table Views in Storyboards iOS 4.2

I want to set up a recursive Table View in Storyboards. By recursive, I mean you click on an item in the TableView and it loads a new instance of the Table View, just with the new data displayed. This way, I can reuse the Table View Cells and logic contained in the Table View Controller. My data is in arrays of arrays of arrays...

The only work around I can find is to set u a navigation controller that has my Table View Controller as the root view controller and then have that Push another instance of my Table View Controller. This second Table View Controller then Pushes the original Table View Controller and I have my recursive Table View Controllers. I'm just trying to eliminate the duplication of the Table View Controller (even though it is only once).

Thanks

Picture For Reference of What I Have enter image description here

like image 531
Tyler DeWitt Avatar asked Oct 19 '11 17:10

Tyler DeWitt


2 Answers

If you expand the Document Outline view on the left side of the Storyboard editor, you can control-drag from the table cell to the same view controller the table cell is in.

like image 199
Koppacetic Avatar answered Oct 13 '22 05:10

Koppacetic


I was trying to do something like this as well. I hooked the Cell Prototype up to the segue by zooming out to a higher level like you have in your screenshot, then right-clicking the cell and dragging down into the TableView. That gave me the usual segue options.

like image 29
jerslan Avatar answered Oct 13 '22 05:10

jerslan