I have a grouped UITableView where not all sections may be displayed at once, the table is driven by some data that not every record may have. My trouble is that the record
I had the same problem in iOS 7 and finally I solved this checking the Height for Header and Footer sections, as Ramesh said:
- (CGFloat)tableView:(UITableView *)tableView heightForHeaderInSection:(NSInteger)section {
if ([[self.tableView objectAtIndex:section] count] == 0)
return 0.01f;
else
return 30.f;
}
- (CGFloat)tableView:(UITableView *)tableView heightForFooterInSection:(NSInteger)section {
return 0.01f;
}
It's curious, but if you set 0.f as the height the sections is showed with a default size and moves down the other sections.