2013-10-01 24 views
2

我也有类似的屏幕: enter image description here的UITableView - 删除分隔符为“无效”行

我想删除低于去年“激活”细胞分离机中的tableView(在这种情况下,一切以下“Kompozytorzy”我哪有。消除这种隔膜?

我尝试自定义分隔在cellForRow:AtIndexPath:,但每次我改变这种影响整体的tableView。

回答

5

这对于只有几行的普通样式表视图正常的行为。一个简单的解决方法是提供一个空表页脚:

self.tableView.tableFooterView = [[UIView alloc] init]; 
1

这是UITableView中的默认行为,它用空行填充屏幕。

你可以做的是设置一个空的页脚到表:

- (UIView *)tableView:(UITableView *)tableView viewForFooterInSection:(NSInteger)section 
{   
    return [[UIView alloc] init]; 
} 

或者:

[self.myTableView setTableFooterView:[[UIView alloc] init]];