I have a form with diffirent widgets. I want to compare between two widget (PassWord and ConfirmationPW), before validate the forme and pass to next task ?
How can i do that ?
Thank you .
I have a form with diffirent widgets. I want to compare between two widget (PassWord and ConfirmationPW), before validate the forme and pass to next task ?
How can i do that ?
Thank you .
Hi Hichem,
You can do that using a form validator (either with groovy or regular expression). When the submit button is clicked, the form validator will compare your two widgets and if they are not the same, the user will see the error message you specified.
You can find the form validator in the form general menu (by clicking anywhere outside your form).
Best regards,
Mehdi
Thank you mehdi.kettani for your answer. I did what u told me , and it works, i put in the message some groovy code like :
if (field_pw!=field_confPw) print (“Error in PW”)
I still have a litle problem. When i execute my form , he shows me the following message : An element with id CréerNewUtilisateur is missing from the page template.
Just for information my process create new users.
So can you tell me how to specify my own error message ?
Check the screenshot here : http://hpics.li/178dbdd
The Error message field should contain the error message you want to be displayed when the comparison fails.
The Parameter field should contain the groovy script performing the comparison (field1.equals(field2) for example).
if it is a simple string message, no need to use groovy to display it. just use a constant message. I tested your print(“Error in PW”) script and it doesnt show up when validation fails (but the form is not submitted). So just write “Error in PW” in Error message field.
Actualy in message error i did :
Print(“Error PW”)
And in the parameter i put tho following code :
(Field_pw != Field_confPw);Is that supposed to work ?
Thank you it works