Good tutorial for Split-View controller that doesent use the default template?

Go To


I'm new to iOS development and am trying to learn how to use the split-view controller. It seems like all the tutorials I can find use the default Master-Detail template. I would like to learn how to set one up off an existing project. Also I'm using Xcode 4.3, ARC, and storyboards...

I've been trying to figure this out for a few days and have read over the tutorial from Ray Wenderlich, Watched a related lecture from the CS193P course on iTunesU, read the Apple documentation, and looked over the code included in the template for a Master-Detail app and read all the tutorials that a simple Google search kicked up and still can't figure this out!

This is starting to get a little frustrating!

Can someone please suggest a GOOD tutorial or give me some code-snippets of how to make a very simple split-view app using storyboards?



2012-04-04 04:44
by Shredder2794
What do you mean by setting it up for an existing project? A Split-View controller is a UIViewController subclass, so as long as you have a UIViewController, you should be able to replace that with a SplitViewController. Not sure if I'm misunderstanding your question - Tilo Mitra 2012-04-05 08:41
All the tutorials I can find start using the defualt Master-Detail template, I want to learn how to add a split view to an existing project whereas if you use the defualt template everything come pre-setup - Shredder2794 2012-04-05 22:31


You do know that a SplitViewController is supposed to be the root (top-level) controller don't you? Therefore you would typically use the Master-Detail Application template (with storyboard or without) and modify/extend it as needed.

Assuming you do know that, then if you wanted to go a purely programmatic approach instead you would create a splitViewController in code just as you would any other view controller as Tilo Mitra said.

Or, have you got an existing iPhone app you now want to upgrade to iPad, and in the process use a split view controller? If so, create a new storyboard file for iPad. Then drag a split view controller object in, then modify / configure as per your needs (all those tutorials you found should help you achieve what you want from there).

2012-07-02 11:28
by ader