In my UITableViewCell
I have a button. And I want to add action to it by passing multiple parameters in cellForRowAtIndexPath
method.
func tableView(tableView: UITableView, cellForRowAtIndexPath indexPath: NSIndexPath) -> UITableViewCell {
let cell = tableView.dequeueReusableCellWithIdentifier("CartCell", forIndexPath:
indexPath) as! CartTableViewCell
cell.buyButton.addTarget(self, action: self.buyButton(indexPath, 2, 3 ,4 , 5, 6), forControlEvents: .TouchUpInside)
}