Advertisement
Guest User

Untitled

a guest
Jan 19th, 2017
74
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.50 KB | None | 0 0
  1. @IBAction func plusBtnAction(_ sender: UIButton) {
  2.  
  3. var cell:TableViewCell = self.tebleView.dequeueReusableCell(withIdentifier: "Cell")! as UITableViewCell as! TableViewCell
  4.  
  5. let indexPath = IndexPath(row: sender.tag, section: 0)
  6.  
  7. cell = (self.tebleView.cellForRow(at: indexPath) as? TableViewCell)!
  8.  
  9. if cell.tag == sender.tag {
  10. print(sender.tag)
  11. print(cell.countLbl.tag)
  12. cell.countLbl.text = "(Int(cell.countLbl.text!)! + 1)"
  13. }
  14. else {cell.countLbl.text = ""}
  15. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement