Contents

Develop
2014.04.08 15:48

[ios] UITableView 특정 Row만 Update

조회 수 4780 댓글 0
?

단축키

Prev이전 문서

Next다음 문서

크게 작게 위로 아래로 댓글로 가기 인쇄
?

단축키

Prev이전 문서

Next다음 문서

크게 작게 위로 아래로 댓글로 가기 인쇄
여러개의 특정 row만 reload 하는 코드
// tableView에 특정 row만 reload 하겠다고 메세지 전달
[tableView beginUpdates];

// reload 하기 위한 indexPath 배열 생성
NSIndexPath *indexPath1 = [NSIndexPath indexPathForRow:1 inSection:0];
NSIndexPath *indexPath2 = [NSIndexPath indexPathForRow:3 inSection:0];

NSArray *array = [NSArray arrayWithObjects:indexPath1, indexPath2, nil];

// 특정 row를 reload
[tableView reloadRowsAtIndexPaths:array
    withRowAnimation:UITableViewRowAnimationFade];

// tableView에 reload 완료 메세지 전달
[tableView endUpdates];



한 개의 특정 row 만을 reload 하는 심플한 코드

[_tableView beginUpdates];

[_tableView reloadRowsAtIndexPaths:@[indexPath]
    withRowAnimation:UITableViewRowAnimationTop];

[_tableView endUpdates];


?

  1. [ios] 카테고리 확장 메소드를 찾지 못하는 경우

  2. [ios] Swift 4 Dictionary 사용하기

  3. [java] netty (비동기 이벤트 방식 네트워크 프레임워크) 사용법 #2 (client)

  4. [ios] 설정에서 푸시 알림(APNS) on/off 상태 확인

  5. [c#] mfc 기반의 웹서비스 서버/클라이언트 샘플과 예제 소스

  6. [android] SQLiteOpenHelper를 이용한 DBManager

  7. [c#] MS IE(Internet Explorer) 툴바 버튼 예제 2003/2005 두가지 버전

  8. [ios] 기본 네비게이션바의 타이틀, back버튼 위치와 속성 변경

  9. [android] 안드로이드 앱 문서 샘플

  10. [c#] 툴바 최근 버전(IE6, IE7 두가지 버전)

  11. [android] 버전 별 앱 알림 설정으로 이동하는 방법

  12. [c#] BHO 한샘툴바랑 동현툴바..

Board Pagination Prev 1 ... 8 9 10 11 12 13 14 15 16 17 ... 71 Next
/ 71