I am working on iOS project which have one table with 2 sections.it also have search bar.In table cell I have a label and a button.in both section coming data from different array.Now problem is that I am not able to recognize cell of the section during tap on button.how i can recognize on that custom button action that which section of button is that? p;ease help me .I am pasting following code.

```
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
{
    static NSString *CellIdentifier = @"Cell";
    UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier];
    if (cell == nil)
    {
        cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleSubtitle reuseIdentifier:CellIdentifier];
    }
    else
    {
        UIView *subview;
        while ((subview= [[[cell contentView]subviews]lastObject])!=nil)
            [subview removeFromSuperview];

    }
    [cell setSelectionStyle:UITableViewCellSelectionStyleNone];

    UILabel *nameLabel=[[UILabel alloc]initWithFrame:CGRectMake(10,12,230,40)];
    [cell.contentView addSubview:nameLabel];
    //lblCal.backgroundColor=[UIColor blueColor];//[UIColor colorWithRed:190 green:0 blue:0 alpha:1];
    nameLabel.textColor=[UIColor blackColor];
    nameLabel.font=[UIFont fontWithName:@"Helvetica" size:18.0];//[UIFont fontWithName:@"Helvetica" size:12.0];
    nameLabel.textAlignment=NSTextAlignmentLeft;
    nameLabel.backgroundColor=[UIColor clearColor];

    UIButton *btn=[UIButton buttonWithType:UIButtonTypeCustom];
    [cell.contentView addSubview:btn];
    btn.frame=CGRectMake(255,0,65, 65);
    btn.tag=indexPath.row;
    [btn addTarget:self action:@selector(sendFollowUnfollowRequest:) forControlEvents:UIControlEventTouchUpInside];
    Team* team;
    if(isFiltered)
    {
        if (indexPath.section==0) {

            team = [filterFollow objectAtIndex:indexPath.row];
            [btn setImage:[UIImage imageNamed:@"icon_check@2x.png"] forState:UIControlStateNormal];
        }
        if(indexPath.section==1)
        {
            team = [filterUnFollow objectAtIndex:indexPath.row];
            [btn setImage:[UIImage imageNamed:@"icon_plus@2x.png"] forState:UIControlStateNormal];

        }
    }
    else
    {
        if (indexPath.section==0) {
            team = [followTable objectAtIndex:indexPath.row];
            [btn setImage:[UIImage imageNamed:@"icon_check@2x"] forState:UIControlStateNormal];

        }
        if(indexPath.section==1)
        {
            team = [unfollowTable objectAtIndex:indexPath.row];
            [btn setImage:[UIImage imageNamed:@"icon_plus@2x.png"] forState:UIControlStateNormal];
        }
    }
    [nameLabel setText:team.teamName];
    return cell;
}

-(void)sendFollowUnfollowRequest:(UIButton *)tag
{
    [self.searchBar resignFirstResponder];
}

```