Reputation: 5413
I have a UITableViewController which contains a UITableView. I try to control the UITableViewController's view to be only 200px tall. UITableViewController.view.frame=CGRectMake(0, 0, 320, 200), but I always getting the UITableView to be full height, the table didn't contrainted to 200 px. How do I control the total height of the UITableView?
Upvotes: 1
Views: 1175
Reputation: 27157
A UITableViewController
s view
property is a UITableView
. You need to change your UITableViewController
subclass's superclass to be UIViewController
. I answered a question here that explains how to do this, and explains the problem in more detail.
Upvotes: 2