trying to hide and customize the height of a static cell. I know this might not be the best way to do it. If anyone know of a better way, please advice.
- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath
{
if (![Mode isEqualToString:@"HIDE"]) {
if (indexPath.row == 2) {
return 0.0;
}
}
return "DEFAUlT_HEIGHT";
}
How to get the default height from the storyboard? Every height of the cells in the storyboard are different. Are there anyway to better customize it? Thanks in advance.
Have a look at this thread : Hide static cells
It talks about hiding static cells programmatically. Here’s the accepted answer :
If this helps, please go over there and up vote henning77’s answer.