I know that this already has an accepted answer, but I decided that I would go a little deeper into the βwhyβ this happened and the solution.
In layman's terms, updating the UITableView delayed at a given view speed. In other words, due to fast scrolling, it is expected that the table view will re-populate the content faster than it can sort the expected cell for reuse for the corresponding index (row).
The simplest solution that Wienke has touched is to create different cell identifiers for the first, let them say three (3). This will allow us to see in the tabular presentation a clear differentiation between 3 cells, preventing any displacement of cells.
Perhaps the best approach here would be to assign the appropriate cell IDs to each cell (depending on the context and number of cells). Thus, the table view knows exactly which cell (with its corresponding identifier) ββgoes there. Something simple as shown below:
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { NSString *cellID = [NSString stringWithFormat:@"cell%lu", indexPath.row]; __kindof UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:cellID]; if (!cell) {
source share