【问题标题】:Remove under line in table view删除表格视图中的下划线
【发布时间】:2018-02-16 00:17:03
【问题描述】:

我想在 TableView 中删除这一行。

我用

tableView.tableFooterView = UIView(frame: CGRect.zero) , 
 tableView.tableFooterView?.isHidden = true, 
 tableView.tableFooterView = nil`, 
 tableView.tableFooterView = UIView(frame: CGRect(x: 0, y: 0, width: tableView.frame.size.width, height: 1))`,

将样式表视图设置为分组并将分隔符设置为无是行不通的。

【问题讨论】:

标签: ios swift uitableview


【解决方案1】:

viewDidLoad()

中使用此代码
tableview.separatorStyle = .none

【讨论】:

    【解决方案2】:

    在属性检查器的 Storyboard 视图控制器中选择您的UITableView,您可以更改separator 的值。

    详情请看这里 screenshot.

    【讨论】:

      【解决方案3】:

      转到 Tableview 属性 -> 在 Dropbox 中选择分隔符并选择无。

      【讨论】:

        【解决方案4】:

        对不起,问题出在我的代码上,所以你无法回答我。

        在我的代码中,我添加到FooterInSection 中的Label,但我不检查。

        感谢所有帮助我的解决方案。

        【讨论】:

          猜你喜欢
          • 1970-01-01
          • 2017-03-17
          • 1970-01-01
          • 2022-08-12
          • 1970-01-01
          • 2016-08-26
          • 2017-03-23
          • 1970-01-01
          • 1970-01-01
          相关资源
          最近更新 更多