MusiGenesis MusiGenesis - 10 months ago 109
iOS Question

How do I make a UITableView stop scrolling

I don't mean that I want to disable scrolling. I want to be able to programmatically tell the table to immediately stop moving (but then it should still be scrollable after than). Is this possible?


A UITableView is a subclass of UIScrollView. If you tell it to scroll to its current position, it will stop scrolling so this should work for you:

[tableView setContentOffset:tableView.contentOffset animated:NO];