Search code examples
iosuitableviewuisplitviewcontroller

Does a UISplitViewController's master view always have to be a UITableView?


I've used UISplitViewController several times before without problems (well, problems that I've fixed anyway ;-) However, I have always previously used a UITableView as the master view, as that's the obvious choice. Today I have need for something a little different, so I'm just providing a UIView.

However, I'm getting the exception,

*** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: '-[UITableViewController loadView] loaded the "MyViewController" nib but didn't get a UITableView.'

I can't find mention in the Apple documentation that the master view must always be a UITableView in the documentation, there's just a reference to the master view being used to display a list.

Is there a rule that the master view must always be a UITableView?


Solution

  • No, it doesn't.

    I'd made a mistake by changing the code for the iPad idiom, but testing on an iPhone - whoops!