In my app, I need to enable Return Key on UITextView even if UITextView is empty. By default, return key is disabled, before user not entered any symbols. How I can do this?
Thanks.
I need to enable Return Key on UITextView even if UITextView is empty.
Actually, the return key is enabled by default no matter the text view is empty or not. However, if you want to set the return key to disabled by default, you need to set the enablesReturnKeyAutomatically
to YES
. As the Apple Doc said:
The default value for this property is NO. If you set it to YES, the keyboard disables the return key when the text entry area contains no text. As soon as the user enters any text, the return key is automatically enabled.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With