DonnaArtis
Canvas Initiate

Count Characters in a Multi-line field

Jump to solution

I'm trying to work out how to count the number of characters in a multi-line textbox in real time, as I have a requirement for the field to have a minimum of 200 characters.  I've searched the form and found a post that counts down from 10 characters, but can't seem to get this to work on my multi-line textbox.

 

Can someone please advise how to get this working.

0 Kudos
Reply
3 Replies
claudiaurbanski
Process Pupil

Re: Count Characters in a Multi-line field

Jump to solution

I've done it to limit characters entered to 9, perhaps it might work for you too.  Try:

[A-Za-z0-9]{9}   or   /^[a-z]{0,9}$/

 

claudiaurbanski_0-1604942409908.png

 

0 Kudos
Reply
SimonMuntz
Nintex Employee
Nintex Employee

Re: Count Characters in a Multi-line field

Jump to solution
Hi,

Use a calculated Value control set as data type Integer with the function:
length(NameOf MultiLineOfTextControl)
This will give you a live count of how many characters are in the control.

Then set a rule on the Multi Lines of text control to make sure it invalidates if there is less than 200 characters.
Rule: lessThan(length(NameOf MultiLineOfTextControl),200)

View solution in original post

0 Kudos
Reply
DonnaArtis
Canvas Initiate

Re: Count Characters in a Multi-line field

Jump to solution

Thanks @SimonMuntz, didn't think it would be as simple as that, I already had the rule for validating the size of the box, just wanted it to display to users.

0 Kudos
Reply