swift - Update label in custom UITableView Cell -
i need update label clicking on button in same cell. why code doesn't work ?
@ibaction func actionfaveunfave(sender: anyobject) { let cell = self.tableview.cellforrowatindexpath(sender.indexpath) println(cell?.labelfavedtimes) cell.labelfavedtimes = "22"}
cell?.labelfavedtimes.text = "22"
btw self.tableview.cellforrowatindexpath(sender.indexpath)
can return nil if cell not visible
Comments
Post a Comment