Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
1110
UltraFormattedTextEditor maximum number of lines and characters
posted

I have to limit the number of lines and characters per line in an UltraFormattedTextEditor. For example: maximum 4 lines and maximum 20 characters per line.

The number of lines is not that difficult, I'm counting the number of crlf's in the keypress event.

But I also want a maximum number of characters per line. I'm having difficulty with this one because I don't know where the user is typing. How can this be done? It's no big deal in itself to check how many characters there are on a line but I would like to prevent the user from entering the character if he tends to exceed the maximum on the line he is typing.

Parents Reply Children
No Data