My case is this:
I have a static table, with hidden cell(height = 0), custom cell that will open keyboard, and a reset button(that will reload table and scroll to top)
What is the problem:
Scroll to top will go to invalid offset.
How to regenerate:
type in the keyboard, reset(which scroll to top and reload the keyboard) and there will be space between my top cell and top of table (just like hidden cell consumed some space)
---
At first I thought it is the hidden cell problem, but it turns out to be problem on [tableView reloadData]
**[tableView reloadData] will interrupt scrolling, so make sure you call [tableView setContentOffset:] or [tableView scrollToRowAtIndexPath:] after all reload is done.
Reference: stackoverflow