StackAccount
StackAccount

Reputation: 151

How to remove table view from a XIB?

I would like to create a navigation based application without the Table View stuff... when I select "navigation based application" at the project start, I get a Root view that inherits from UITableViewController... I wish to inherit from UINavigationController and delete all the table methods in the implementation file... question is...

how do I change the XIB in interface builder to give a simple UIView rather than UITableView?

please and thank you

Upvotes: 1

Views: 1528

Answers (3)

shweta thakar
shweta thakar

Reputation: 1757

First Delete the UITableView from .xib then add the view in .xib and delete the UITableViewController from .h class and edit it with UIViewController.

Upvotes: 0

NWCoder
NWCoder

Reputation: 5266

It is simple, but some people forget a few steps.

  1. delete the table view
  2. add a view
  3. make sure to wire up the outlet for the viewcontroller.view
  4. in the .h file change the super class to view controller, rather than tableview controller.

Upvotes: 3

Rayfleck
Rayfleck

Reputation: 12106

In the Objects list, select the TableView, press Delete.

enter image description here

Then drag in whatever type of view you want, like a NavBar controller.

Upvotes: 4

Related Questions