Andrew Andrew - 1 year ago 129
Objective-C Question

Hiding UITableViewCell separator for individual cells

I require a UITableViewCell separator for the majority of my cells, but some of them should be hidden.

The way this is set is

, which would apply to every cell.

A heavy-handed work around is to disable it, and then draw it onto cells manually as a UIView, but I don't want to go there.

How can I otherwise remove the separator for individual cells?

Answer Source

You can have custom cell and add separator in this cell, this way you can manage your cell separator. Or you can addSubView a UIView for separator to your cell like iPatel's answer, but be careful for memory issue.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download