设置UItabelView的头部视图:
/**
* 设置头部视图
*/
-(UIView*)tableView:(UITableView *)tableView viewForHeaderInSection:(NSInteger)section{
if (section == 0) {
return self.handerView;
}else{
return nil;
}
}
/**
* 设置头部视图的高度
*/
-(CGFloat)tableView:(UITableView *)tableView heightForHeaderInSection:(NSInteger)section{
if (section == 0) {
return 350;
}else{
return 0;
}
}
网友评论