看板 [ MacDev ]
討論串[問題] tableviewcell的indexPath.row
共 3 篇文章
首頁
上一頁
1
下一頁
尾頁

推噓0(0推 0噓 1→)留言1則,0人參與, 最新作者nobody1 (無事家中坐)時間11年前 (2014/04/02 01:31), 編輯資訊
0
0
1
內容預覽:
sample code. if (cell==nil){. cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:cellIDT];. [cell setSelectionS
(還有316個字)

推噓0(0推 0噓 1→)留言1則,0人參與, 最新作者Jeching1209 (JeChing)時間11年前 (2014/04/01 18:33), 編輯資訊
0
0
1
內容預覽:
按照你的描述似乎是在cellForRowAtIndexPath:. 這個 delegate 裡加 button. 最直接解決的方法. 在 cell.contentView addSubview: 之前. 加入. for (UIView *subview in cell.contentView.sub
(還有9個字)

推噓2(2推 0噓 8→)留言10則,0人參與, 最新作者yoyostar1990 (~Yoyo~)時間11年前 (2014/03/27 00:26), 編輯資訊
0
0
1
內容預覽:
用tableviewcell來顯示資料庫資料. 而每筆資料有個button可以選擇. 但有default資料. default資料不想讓他有button. 不知道要怎麼實現. 原本是使用indexPath.row > 3 才加button. 但只有剛進去是正確的. 上下滑動後全部都會加到button
(還有56個字)
首頁
上一頁
1
下一頁
尾頁