1개의 UIViewController에 2개의 TableViewController 넣기
//Outlet 생성
@property (nonatomic, weak) IBOutlet UITableView* firstTableView;
@property (nonatomic, weak) IBOutlet UITableView* secondTableView;
//Tableview
-(UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath {
...
if (tableView == self.firstTableView) {
...
} else { // tableView == self.secondTableView
...
}
}
return cell;
'IOS > Swift' 카테고리의 다른 글
Swift의 Type checking (0) | 2016.05.07 |
---|---|
String형식으로 응답받은 String Array를 String으로 만들기 (0) | 2016.02.27 |
Segue의 정리 (0) | 2016.02.25 |
Modal이나 Alert 띄울때 반투명 백그라운드 (0) | 2016.02.22 |
UIViewController안에 UITableView 넣는법 (0) | 2016.02.21 |
댓글 로드 중…
트랙백을 확인할 수 있습니다
URL을 배껴둬서 트랙백을 보낼 수 있습니다