I would like to limit the user of my iPad application to a maximum of 20 lines when output to pdf. The user enters text into a UITextView (as shown below) and then converts to a pdf document.

I understand that I will have to do several calculations depending on what text is entered as they are entered. Are there any methods that can help me here? textFieldDidEndEditing allows me to check after it has been entered.
Also, since that would be much simpler, is there a way to limit the number of rows a UITextField ?
ios uitextfield ipad
Rgriffiths
source share