猫猫学iOS之tableview隐藏最下边多余的cell

219 阅读1分钟
原文链接: blog.csdn.net

效果图

这里写图片描述

最下方cell显示的不够了,但是猫猫不想看到那些线,这里共享一种方法

解决方法

在- (void)viewDidLoad 方法中写入

    //隐藏多余cell
    self.tableView.tableFooterView = [[UIView alloc] initWithFrame:CGRectZero];

就可以达到目的了

看图这里写图片描述