0
votes

This should be a fairly general question, but I have a view in which I placed a UITableView and implemented it properly. It works well and it scrolls. But I want to add a UISearchBar attached to it so that it will scroll along with the table. But when I add the search bar onto the tableview it shows up, but the tableview will not scroll anymore. I don't actually need any input into the search bar, and I disabled user interaction. Is there any way to add the search bar (no need to implement it) and have it scroll?

(I will rate up anyone who answers!)

Thanks

2

2 Answers

0
votes

The UISearchBar should be the UITableView's header view.

0
votes

Had similar issue even when IB had the correct bouncing properties enabled.

In your viewDidLoad, set self.tableView.alwaysBounceVertical = YES;.