I have Implemented tableview named as mytableview inside UIView
in UITableviewController
named as maintablevew,and also I dynamically increased mytableview height based on cells count.it getting Increased Dynamically,Here my problem is when mytableview height getting increased I can't scroll upto bottom because I can't increased UIView height Dynamically,I don't know how to increase,can anyone suggest? Below code I used to increase mytableview height Dynamically.
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
CGFloat numberOfRows =roomlabel.count;
CGRect tableViewFrame = tableView.frame;
tableViewFrame.size.height = numberOfRows * _mytableview.rowHeight;
_mytableview.frame = tableViewFrame;
return numberOfRows;
}
You don't need to increase(change) the height of the UITableView or UIView, You just have to provide cell height, It will automatically update it's content size, and table will become scrollable.