These forums are now Read Only. If you have an Acrobat question, ask questions and get help from one of our experts.

Checkbox validations

Runolfr
Registered: Oct 1 2008
Posts: 119

Is there an easy script to verify that at least one of a group of checkboxes is marked?

For instance, my form has a checkbox to say whether a person requires a regular medical treatment. If it's checked, then the user should have to check one or more boxes corresponding to days of the week on which treatment is received.

George_Johnson
Expert
Registered: Jul 6 2008
Posts: 1876
Are you using Acrobat or LiveCycle Designer to create your form?

The answer to your question is yes, but when (in response to what?) do you want the code to run?

George
Runolfr
Registered: Oct 1 2008
Posts: 119
I'm using LiveCycle Designer 8.2.

I can use the onChange event of a checkbox to change whether other controls on the form become required, but I don't know how to easily validate that "at least one of this group of checkboxes is checked" before the form gets submitted. I don't know if that should be part of the validate event or the preSubmit event.