How to reset some form fields without resetting all with Acrobat 7

Learn how to create a reset button within your PDF form that only resets 'some' but not all of the fields.

By August 23, 2006

 

Is it possible to create a reset button within your PDF form that only resets "some" but not all of the fields?

Since there are two types of PDF forms — forms created with the Acrobat tools, and forms created with Adobe LiveCycle Designer — we'll give two examples that show how this can be done.

Acrobat forms:

  • Select the action “Reset a form,” and then select the individual fields to be reset in the Reset a Form dialog box.
  • In Figure 1, the form has three fields, but the button only resets the field “Name.”


Figure 1: From the Reset a Form dialog box select only the fields that should be reset.
See larger image

LiveCycle forms:

  • In order to reset individual fields, you must add some JavaScript to the button object.
  • On the mouseUp or Click event, add xfa.host.resetData("[field name]") For example, if you look at Figure 2, to reset the field “Name,” you would add xfa.host.resetData("F.P1.Name") that explicitly identifies the field as part of Form “F,” page “P1,” field “Name.”


Figure 2: Add JavaScript to the reset button to specify which fields to reset.
See larger image


Did you know?

  • You can ask a question and get an answer from one of our experts.
  • You can search our database of over 800 tutorials by product and/or topic.
  • You can leave a comment below for the author of this tutorial.

Related topics:

PDF Forms

Top Searches:

Convert existing forms to fillable PDFs, fill and sign any form

5 comments

Comments for this tutorial are now closed.

Lori Kassuba

9, 2016-02-18 18, 2016

Hi Leanie,

Try selecting just off to the side. It’s a known bug.

Thanks,
Lori

Leanie

9, 2016-02-11 11, 2016

I want to reset all but 3 fields with Acrobat Forms but it doesn’t want me to only select a few. I either have the option of “select all” or “deselect all”. Can someone help me please

Sandy

9, 2012-09-06 06, 2012

Thanks it works perfectly!
Also, if you have so many fields in one page, and you would like to have a reset button only for the fields in that page, then you can do a page-level reset:

xfa.host.resetData(“Formname.Pagename”);

Sandy - thanks for letting us know how this is done for just one page on a form created in Livecycle Designer.

Lori K.

LORI DEFURIO

2, 2012-08-16 16, 2012

Hi CJ - it’s totally possible with image fields in the current version. I have a piece of JavaScript code - please email me - [email protected] and I’ll send it to you.

CJ

11, 2012-08-14 14, 2012

Does not work for image fields. Has anybody an idea why?

Lee

8, 2012-07-14 14, 2012

Worked like a charm!

Comments for this tutorial are now closed.