通过tag值获得相应的控件 and 在didSeclec方法中获得TableView中得相应cell

1、通过tag值获得相应的控件

UIButton *btn = (UIButton *)[self viewWithTag:currentIndex];

通过tag值递归搜索当前self的View上的所有控件,包括自身

2、didSeclec方法中获得TableView中得相应cell

- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
    UITableViewCell *cell = [self tableView:tableView cellForRowAtIndexPath:indexPath];
}

 

posted on 2015-10-12 09:34  进化的蜗牛  阅读(288)  评论(0编辑  收藏  举报