As you can see in this image
the UITextView changes it\'s height according to the text length, I want to make it adjust it\'s height according to the te
UITextView
this Works for me, all other solutions didn't.
func adjustUITextViewHeight(arg : UITextView) { arg.translatesAutoresizingMaskIntoConstraints = true arg.sizeToFit() arg.scrollEnabled = false }
In Swift 4 the syntax of arg.scrollEnabled = false has changed to arg.isScrollEnabled = false.
arg.scrollEnabled = false
arg.isScrollEnabled = false