You are viewing limited content. For full access, please sign in.

Question

Question

Regular expression field value start

asked on August 10, 2020

I have a field on a form that I would like to ensure users fill out said fields starting w/ a certain set of values (OP or MP) (ie: OP12345). can regular expressions do this? 

0 0

Replies

replied on August 10, 2020

Chris,

The following will match either OP or MP with a 5 digit number proceeding it:

^(OP|MP)?[0-9]{5}

 

1 0
replied on August 10, 2020

Is this java/ CSS?. I put this in the advanced section of the field and it did not work. 

0 0
replied on August 10, 2020

Chris,

 

Place a single line text box control on your form and click on the "Edit" tab of the control. When the "Edit" box of the control is visible click on the "Advanced" tab. Copy and paste the regex that I posted earlier in the "Regular expression for validation" textbox. Click "Done" and then test.

Screenshot_2020-08-10 Layout Laserfiche Forms.png
0 0
replied on August 24, 2020

Works great thank you!!

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.