0
votes

I want to achieve next things in my UITableViewController:

  1. Have transparent table Header View with fixed height.
  2. Have solid colored Table Footer View (for example with white color).

To achieve this I need to set my TableViews’ background to clearColor. But once I set whole tableView backgroundColor to clearColor my header and footer also gets transparent, and I don’t need footerView as transparent.

You may say: use TableView inside UIViewController, but I can’t do it, because I’m using static cells with dynamic height, and static TableView will never conform UITableViewDataSource protocol (only way to change cell heights dynamically), because I haven’t got methods like tableView(cellForRowAtIndexPath).

Example image

1

1 Answers

0
votes

Try setting the tableFooterView property:

tableView.tableFooterView = UIView()

Hope this helps!