2

enter image description here

I have a cell like this

The inside tableView is not scroll enable, but has dynamic cells, and dynamic contentSize

The tableView's height depends on cells

When I use UITableViewAutomaticDimension to auto size for the cell,

contentTableView.rowHeight = UITableViewAutomaticDimension

it's not working for the inside tableView

it just show Labels of the cell, but not tableView

Any Answers? Thanks

Jitendra Modi
  • 2,344
  • 12
  • 34
user1960970
  • 147
  • 10
  • [This answer](http://stackoverflow.com/questions/39868532/can-i-change-height-of-uitableviewcell-real-time/39870884#39870884) could be useful to your case. – Ahmad F Dec 15 '16 at 09:03
  • try this : http://stackoverflow.com/a/18746930/3901620 – KKRocks Dec 15 '16 at 09:23

1 Answers1

0

First Write this in viewDidLoad

self.tableView.rowHeight = UITableViewAutomaticDimension;
self.tableView.estimatedRowHeight = 44.0;

Set numberOfLine property to 0 in StoryBord

Set UILable autolayout to Leading Trailing Top Bottom from SuperView

Hope it will work...

For Detail Description Refer this Answer

Community
  • 1
  • 1
Dheeraj D
  • 4,386
  • 4
  • 20
  • 34