Is there a way to get the number of lines a multi line text field has? It is a dynamic text field, and I need the number of lines of text has been outputted to it. I assumed it would be a property of textfield, but it's not. Thanks.
Printable View
Is there a way to get the number of lines a multi line text field has? It is a dynamic text field, and I need the number of lines of text has been outputted to it. I assumed it would be a property of textfield, but it's not. Thanks.
You can retrieve the total number of lines loaded into a textfield like this:
Suppose you have a textfield with an instancename of myText
PHP Code:// number of lines showing in myText:
numlines = (myText.bottomScroll - myText.scroll)+1;
// number of lines you can scroll down:
myMaxScroll = myText.maxscroll;
// total number of lines:
myTotalLines = numLines + (myMaxScroll-1);
I know this is really old but I just wanna say thanks, this saved my bacon today! :thumbsup::thumbsup::thumbsup: