I have two fields:
txtStageContent (where the user types in information)
WordCountResult (this field displays the words counted in the txtStageContent)
in the exit event for txtStageContent I have the following code to count the number of words (which works):
var cnt = word_count(this.rawValue);
WordCountResultTwo.rawValue = cnt.toString();
function word_count(textParam)
{
textParam = textParam.replace(/^\s*|\s*$/g,'');
if (textParam)
return textParam.split(/\s+/).length;
else
return 0;
}
My Question is:
I would like to have a limit of 700 words in the txtStageContent text field, can this be done?
Thanks in advance for your help!!