aryaxt aryaxt - 3 months ago 11
iOS Question

iOS - UITableView refresh table properly?

I have lots of data and lots of rows in my tableView.
when data changes I want to update my visible cells on the screen, I really don't want to use reloadData because it's an expensive call.

Is it possible to somehow update the visible cells only?
I tried calling :

beginUpdate
&
endUpdate
on the table, but that doesn't work all the time?

Any suggestions?

Answer

You can:

[tableView reloadRowsAtIndexPaths:[tableView indexPathsForVisibleRows] 
                 withRowAnimation:UITableViewRowAnimationNone];