tags:

views:

42

answers:

0

Hello everyone,I have a problem about UITableView which surrounded me for days.I have build a UITableView with 4 sections.Each section's HeaderView has a UIButton. Everything works fine except one thing that when i scroll the selected cell to the top Then the buttons on the headers that bellows the current section will disappear.I try the reload method and it does't work. But When I scroll the invisible buttons to the botttom and drag them out ,then they will apear again. What is the matter? Anyone know?

CellContentObj *newSelected = [level1CellArray objectAtIndex:row];
    [self foldCell:selectedModule];
    int curRow = [self getIndexByObject:newSelected];
    self.selectedModule = [level1CellArray objectAtIndex:curRow];   
    [self unfoldCell:selectedModule atRow:curRow];

    if(curRow == row)
        return;
    [_tableView deselectRowAtIndexPath:self.currentSelectedPath animated:NO];
    [_tableView selectRowAtIndexPath:[NSIndexPath indexPathForRow:curRow inSection:self.currentEditBook]
                            animated:YES
                      scrollPosition:UITableViewScrollPositionMiddle];