I am making chat application, here how to set label and cell height according to text coming from textfield.
How to set initially cell height = 50, then should change height accordingly text from textfield.
but initially i am getting small cell why?
i have given constraints for label
leading = 100, trailing to imageview = 10, top = 0, bottom = lessthenorequalto 0
for image constraint:
top = 20 height, width = 50 trailing = 20
this is the code:
override func viewDidLoad() {
super.viewDidLoad()
tableView.register(UINib(nibName: "ReceiverChatTableViewCell", bundle: nil), forCellReuseIdentifier: "ReceiverChatTableViewCell")
tableView.register(UINib(nibName: "ReceiverChatTableViewCell1", bundle: nil), forCellReuseIdentifier: "Cell")
self.tableView.estimatedRowHeight = 80
self.tableView.rowHeight = UITableView.automaticDimension
//tableView.reloadData()
}