ios - Section within a section for UITableView -
i have create uitableview has sections within sections have never done before , not sure if possible.
this needs like
- header 1
- sub header 1
- cell 1
- cell 2
- cell 3
- sub header 2
- cell 1
- cell 2
- sub header 1
- header 2
- sub header 1
- cell 1
- sub header 2
- cell 1
- cell 2
- sub header 1
all fields dynamic, there 0 or more header sections.. uitableview best way go this? if how approach this?
any appreciated.
there no easy way it, have plan cleverly.
from numberofsectionsintableview return number of "header".
for each section in numberofrowsinsection return sub header + cell in each sub header.
from cellforrowatindexpath chek if sub header or cell. if sub header return cell has label near left side, if cell return cell has label in more far away left border.
you can use same cell changing frame of cell's label.
hope helps.. :)
Comments
Post a Comment