tableView刷新指定的cell 或section和滚动到指定的位置
转自:http://blog.csdn.net/tianyou_code/article/details/54426494
//一个section刷新 NSIndexSet *indexSet=[[NSIndexSet alloc]initWithIndex:];
[tableview reloadSections:indexSet withRowAnimation:UITableViewRowAnimationAutomatic]; //一个cell刷新 NSIndexPath *indexPath=[NSIndexPath indexPathForRow: inSection:];
[tableView reloadRowsAtIndexPaths:[NSArray arrayWithObjects:indexPath,nil] withRowAnimation:UITableViewRowAnimationNone]; // 滚动到指定位置
[self.tableView reloadData];
NSIndexPath * dayOne = [NSIndexPath indexPathForRow: inSection:];
[self.tableView scrollToRowAtIndexPath:dayOne atScrollPosition:UITableViewScrollPositionTop animated:YES];
tableView刷新指定的cell 或section和滚动到指定的位置的更多相关文章
- iOS TableView如何刷新指定的cell或section
指定的section单独刷新 NSIndexSet *indexSet=[[NSIndexSet alloc]initWithIndex:indexPath.row]; [tableview relo ...
- [IOS 开发]TableView如何刷新指定的cell 或section
//一个section刷新 NSIndexSet *indexSet=[[NSIndexSet alloc]initWithIndex:]; [tableview reloadSections:ind ...
- TableView刷新指定的cell 或section
//一个section刷新 NSIndexSet *indexSet=[[NSIndexSet alloc]initWithIndex:]; [tableview reloadSections:ind ...
- iOS: TableView如何刷新指定的cell 或section
//一个section刷新 NSIndexSet *indexSet=[[NSIndexSet alloc]initWithIndex:2]; [tableview reloadSections:in ...
- ios UITableview 刷新某一个cell 或 section
//一个section刷新 NSIndexSet *indexSet=[[NSIndexSet alloc]initWithIndex:]; [tableview reloadSections:ind ...
- UITableview刷新某一个cell或section
//一个section刷新 NSIndexSet *indexSet=[[NSIndexSet alloc]initWithIndex:2]; [tableview reloadSections:in ...
- IOS UITableView reload 刷新某一个cell 或 section
通常刷新整个列表 我们都使用[self.tableView reloadData]; 有的时候,有变化更新的只是某一行 row 或者是某个section 所以只更新这一行就好了 //一个section ...
- TableView刷新 局部刷新等
1.对整个页面刷新 [ tableView reloadData]; 2.对某一个section刷新 NSIndexSet *indexSet=[[NSIndexSet alloc]initWithI ...
- CollectioView滚动到指定section的方法
项目中的需求:collectionView顶部有一个scrollView组成的标签,点击标签,让collectionView滚动到指定的行,滚动collectionView自动切换到顶部指定的标签 实 ...
随机推荐
- ORACLE 36进制和10进制,互相转换函数
第一部分 --36转10进制 create or replace function f_36to10 (str varchar) return int is returnValue int; s ...
- 目标检测之显著区域检测---国外的一个图像显著区域检测代码及其效果图 saliency region detection
先看几张效果图吧 效果图: 可以直接测试的代码: 头文件: // Saliency.h: interface for the Saliency class.////////////////////// ...
- 点击其它地方关闭DIV
<!DOCTYPE html> <html> <head> <meta charset="utf-8" /> <title&g ...
- iOS开发 如何检查内存泄漏
本文转载至 http://mobile.51cto.com/iphone-423391.htm 在开发的时候内存泄漏是不可避免的,但是也是我们需要尽量减少的,因为内存泄漏可能会很大程度的影响程序的稳定 ...
- c#4.5新语法--自动属性和隐式类型
1.自动属性 自动属性是c#中属性定义的两种形式的一种:传统属性定义.自动属性. 1.1 传统属性定义 private int _age; public int ...
- SpringBoot-(1)-IDEA创建SpringBoot项目并运行访问接口
一,安装IDEA mac安装IDEA IDEA配置Tomcat 二,创建SpringBoot项目 1,打开IDEA,点击Create New Project 2,选择自己所安装的JDK.如果没有配置J ...
- EF 编程经验
http://blog.csdn.net/itmaxin/article/details/47662151 这篇文章里有一下东西可以参考,但是弟二个方法明显是不可行的,因为我做了实验直接attach ...
- 02-线性结构1 两个有序链表序列的合并(15 point(s)) 【链表合并】
02-线性结构1 两个有序链表序列的合并(15 point(s)) 本题要求实现一个函数,将两个链表表示的递增整数序列合并为一个非递减的整数序列. 函数接口定义: List Merge( List L ...
- 从数据的角度带你深入了解IPFS
IPFS 和区块链有着非常紧密的联系, 随着区块链的不断发展,对数据的存储需求也越来越高.本文从IPFS 的底层设计出发, 结合源代码, 分析了IPFS 的一些技术细节. 一.概述 IPFS 和区块链 ...
- BZOJ 2023 [Usaco2005 Nov]Ant Counting 数蚂蚁:dp【前缀和优化】
题目链接:http://www.lydsy.com/JudgeOnline/problem.php?id=2023 题意: 有n个家族,共m只蚂蚁(n <= 1000, m <= 1000 ...