Copy link to clipboard
Copied
I am trying to limit the amount of characters a person can fill in a text field. I am having issues with the errors still showing up after the right amount of characters are filled in on the forms text field. I am using the Validation - Regular Expression to limit the amount of characters. The person filling out the form can only use 2-16 characters in length which will be a username. Then I have one for a password text field that is giving me errors too. The password has to be 3-8 characters with 1 capital letter and 1 number minimum. Here is my regexp formulas -
Username -
:custom(regexp="^[a-z0-9](?=.{1,15}$)\w+$")
Password -
:custom(regexp="^(?=.*[A-Z])(?=.*\d)[A-Za-z0-9](?=.{2,7}$)\w+$")
Any help would be greatly appreciated. The reason for this is to have a tech in the field with a tablet that can sign up a customer right there on said tablet and fill out the information to get them installed.
The error that is happening is that it is not accepting the proper input when someone fills the text fields out. It still shows them being red and giving the error message.
Excellent!
In the screenshot, I can see that you are adding the full text tag directive into the Regular Expression field.
Only enter the expression. The :custom(regexp="") part is only used when you are defining the parameters of a field through the text tag process.
In the drag and drop field experience, you only need to provide the ^(?=.*[A-Z])(?=.*\d)[a-zA-Z\d]{3,8}$ part.

Copy link to clipboard
Copied
Greetings!!
RegEx is pretty deep, and I'm not an expert, but this is how I'd approach your situation:
Username: ^[a-zA-Z0-9]{2,16}$
You specified 2-16 characters. I chose to read that as 2-16 alpha/numeric characters, though you could add special characters in there if you wanted.
Password: ^(?=.*[A-Z])(?=.*\d)[a-zA-Z\d]{3,8}$
You specified 3-8 characters, but only gave two required criteria, so I just added in the lower case character set as that seemed most logical for a password. Again, special characters could be added.
Hope this works for you!
Copy link to clipboard
Copied
I tried that and it still shows that it is not following the rules with the fields. I was reading and it says that with the RegEx, that field will only allow one rule and if there are many rules in there, it will ignore the rest and only follow the first rule.
Copy link to clipboard
Copied
In my testing, both of these regular expressions are working as I expect them to. Which one isn't working for you (or do both not work)?
Also, if you can please let me know if you are using the in-app drag and drop environment or text tags. It shouldn't matter but could be helpful.
I wanted to research what you said about only one rule being applied, and the closest thing I found was in the text tag guide. This is what I found:
"A single field can only include one directive for validation. If multiple validation rules are specified in a single text tag, only the first validation rule gets applied. All subsequent validation rules are ignored."
If this is what you are referring to, the statement is about validation directives (meaning date or number or zipcode as types of validations), not the criteria within the regular expression.
Copy link to clipboard
Copied
Ok, yeah, I was reading that. I should also mention that when this is sent to someone (one of my separate emails and I open it on an iPad, it takes that person to a website where they fill this out, like in Safari). Here is a screenshot of what I am trying to do with Adobe Sign -

And yes, it is happening with both!.
Copy link to clipboard
Copied
Excellent!
In the screenshot, I can see that you are adding the full text tag directive into the Regular Expression field.
Only enter the expression. The :custom(regexp="") part is only used when you are defining the parameters of a field through the text tag process.
In the drag and drop field experience, you only need to provide the ^(?=.*[A-Z])(?=.*\d)[a-zA-Z\d]{3,8}$ part.

Copy link to clipboard
Copied
Greetings,
I am fairly new to Adobe Sign Text Tagging and am amazed at the complexity of your tags.
Here is my regexp formulas -
Username -
:custom(regexp="^[a-z0-9](?=.{1,15}$)\w+$")
Password -
:custom(regexp="^(?=.*[A-Z])(?=.*\d)[A-Za-z0-9](?=.{2,7}$)\w+$")
Is there an advance Adobe Sign Text Tag guide or other resources where a novice could learn these more complex tags?
Find more inspiration, events, and resources on the new Adobe Community
Explore Now