Hello,
I am trying to validate the value in a field but it is proving difficult and I cannot see why.
I have a form with a field where I want the user to enter a value but the minimum value should be 20.00. How can I get the form to validate that the value entered is not less that 20.00?
Luther
I am trying to validate the value in a field but it is proving difficult and I cannot see why.
I have a form with a field where I want the user to enter a value but the minimum value should be 20.00. How can I get the form to validate that the value entered is not less that 20.00?
Luther
Hi Luther,
In the text input settings Validation tab add a Custom validation function e.g. checkMin. I also set the Mask to Integer.
In the Setup tab add a Load JavaScript action to the On Load event and add this code:
You may also want to add a custom validation error message using the Title box.
Bob
In the text input settings Validation tab add a Custom validation function e.g. checkMin. I also set the Mask to Integer.
In the Setup tab add a Load JavaScript action to the On Load event and add this code:
function checkMin(el) {
return ( el.val() >= 20 );
}
That seems to work OK.
You may also want to add a custom validation error message using the Title box.
Bob
This topic is locked and no more replies can be posted.