美文网首页
iOS 点击btn 确定cell

iOS 点击btn 确定cell

作者: J_HX | 来源:发表于2017-07-19 10:52 被阅读12次
  1. 第一种方法,这个方便一点点,不用设置tag。

NSLog(@"MyRow:%d",[self.table indexPathForCell:((TableViewCell)[[sender superview]superview])].row);
 2. 第二种方法,这个需要加载cell时设置tag.不过也很方便。
NSLog(@"MyRow:%d",((TableViewCell
)[[sender superview]superview]).tag);

相关文章

网友评论

      本文标题:iOS 点击btn 确定cell

      本文链接:https://www.haomeiwen.com/subject/yfflkxtx.html