Copy link to clipboard
Copied
I am creating a form and I want it to check a box of met or unmet depending on a text field entry. So if the text field is less than 5% I want the box of unmet to be checked. Any idea how I can make that happen.
Use this code as the custom validation script of the percentage field:
this.getField("Criterion3Met").checkThisBox(0, (Number(event.value)>=5));
this.getField("Criterion3Unmet").checkThisBox(0, (Number(event.value)<5));
Copy link to clipboard
Copied
What are the names of the fields? Is the text field set to the Percentage format option, or to Number, or to None?
Copy link to clipboard
Copied
The field is set as a number text field and the field I want it to fill is just a check box.
Copy link to clipboard
Copied
What is the name of the check-box field?
Copy link to clipboard
Copied
The check boxes are Criterion3Met and Criterion3Unmet. The percentage field is named percentage. If it is less than 5% it will need to check Criterion3Unmet and if it is greater than 5% it will need to check Criterion3Met.
Copy link to clipboard
Copied
Sorry should be greater than or equal to 5% for the Criterion3Met.
Copy link to clipboard
Copied
Use this code as the custom validation script of the percentage field:
this.getField("Criterion3Met").checkThisBox(0, (Number(event.value)>=5));
this.getField("Criterion3Unmet").checkThisBox(0, (Number(event.value)<5));
Copy link to clipboard
Copied
That worked amazing thank you so much!! One more question...If I have a all fields named the same such as counselorrow1 it fills all the other fields perfectly but I want to lock all the other fields once they populate the names is this possible?
Copy link to clipboard
Copied
Sorry, I don't follow... You want to lock a field once it has a value? What if the user wants to change it?
Copy link to clipboard
Copied
I only want the boxes locked that auto fill from the first one filled in. So on page one they enter a name into the counselorrow1 box it fills through all of the pages then I want it to lock the other pages from being able to edit that field but they can still edit the field on page one.