PDF Editing Issues

Clear Specific Checkbox Groups in an Adobe Acrobat PDF Form

Tauseeq MagsiTauseeq Magsi Nov 25, 2026 868 views

Question details

The user needs a PDF form button to clear only checkboxes whose field names begin with Potential.

Clear Specific Checkbox Groups in an Adobe Acrobat PDF Form
Product
Adobe Acrobat
Device & OS
not provided
Scenario
A form button should reset a specific set of checkboxes without changing other fields.
Observed behavior
The current JavaScript using getArray does not clear the intended checkboxes.
Before you start

Open the PDF in Adobe Acrobat and select Prepare a form to inspect the exact checkbox field names and their default values. Make sure the form contains a button where you can add a JavaScript action.

Solution 1Recommended

Reset a Hierarchical Checkbox Group

Use this method when the checkboxes share a parent field name and their default values are unchecked.

1
Check the field names

In Prepare a form, inspect the checkbox names. Name the fields using a common parent, such as Potential.check1, Potential.check2, and Potential.check3, if appropriate.

2
Open the button action

Double-click the form button, open the Actions tab, choose a trigger such as Mouse Up, and select Run a JavaScript as the action.

3
Add the reset script

Click Add and enter: this.resetForm(["Potential"]); Save the action and close the button properties.

4
Test the button

Preview the form, select checkboxes in the Potential group and elsewhere, then click the button. Confirm that the Potential fields return to their default values while unrelated fields remain unchanged.

Reset a Hierarchical Checkbox Group
Check default values: resetForm restores default values rather than always unchecking fields. Ensure the Potential checkboxes are unchecked by default if the button must clear them.
Free Microsoft Office alternative

Work with PDF Forms and Office Files in WPS Office

WPS Office is a free, lightweight alternative with a familiar interface for working with PDFs and Office documents. Its format compatibility helps make moving everyday documents straightforward; use Adobe Acrobat to edit and test the form's JavaScript.

Open and review PDF forms alongside other documentsCompatible with Microsoft Word, Excel, and PowerPoint formatsFamiliar interface for a straightforward transitionFree, lightweight tools for everyday office tasks
microsoft office alternative - wps office

Frequently Asked Questions

Why doesn't getArray find fields named Potential0 and Potential1?

getArray works with a field's hierarchical children; a shared text prefix alone does not make separately named fields a group. Use a parent name such as Potential.check1 and Potential.check2, or address the numbered fields individually.

Will resetForm always uncheck the selected boxes?

No. It restores the fields to their default values. Check the defaults in Prepare a form, or set each checkbox value to "Off" when the goal is to uncheck it explicitly.

Where do I add the button script in Acrobat?

Open Prepare a form, double-click the button, and select the Actions tab. Choose a trigger such as Mouse Up, select Run a JavaScript, and click Add.

How can I clear more than five numbered checkboxes?

In the button's JavaScript action, adjust the loop's starting and ending numbers to match the field names. For example, use i <= 9 for fields Potential0 through Potential9.