I am trying to limit the number of characters (2,500) or words (350) in a multiple choice question that allows text entry (e.g., other please specify response).
I know I have 2 options: a) custom validation using regex or b) javascript. I tried the following regex but it did not work.
^(?:\\b\\w+\\b*){1,350}$
Anything longer than 1 line in the text box gets flagged. Below you'll see an example I used that should not have been flagged and it was.
Any suggestions?
Solved
Limit characters words in multiple choice text entry
Best answer by smgreenPhD
I was actually able to figure out a regex solution before I saw your latest response.
For regex, I used this:
^\\W*(?:\\w+\\b\\W*){0,350}$
Leave a Reply
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.