Your code is wrong try this:
- (CGFloat)tableView:(UITableView *)tableView heightForViewForHeaderInSection: (NSIndexPath *)indexPath
{
if(indexPath.section == 0) // First section
{
return 300;
} else if(indexPath.section == 1) { // Second
return 50;
}
else { // Any other section
return 40.0; // Default
}
}
1
solved Two different heights for sectionHeaderView