【问题标题】:Is it possible to refresh a portion of the ui table view without refresh other cells?是否可以在不刷新其他单元格的情况下刷新 ui 表视图的一部分?
【发布时间】:2010-10-07 14:10:08
【问题描述】:
是否可以刷新某些单元格而不刷新表格视图中的其他单元格?
我需要同时删除、插入和添加一些单元格。为此,我想经常刷新表格。
[self.tableView reloadData];
- 此代码用于刷新我认为的表中的所有单元格。我不确定。因为我的表格包含大量单元格,可能需要一些时间才能重新加载所有单元格。
在此先感谢....
【问题讨论】:
标签:
uitableview
refresh
tableview
partial-page-refresh
【解决方案1】:
是的,试试- (void)reloadRowsAtIndexPaths:(NSArray *)indexPaths withRowAnimation:(UITableViewRowAnimation)animation。另见:insertRowsAtIndexPaths:withRowAnimation:、deletetRowsAtIndexPaths:withRowAnimation:。