How to use basic calculations in PDF forms using Acrobat X or XI

Learn how to calculate fillable PDF forms using Adobe Acrobat X or XI.

By February 6, 2012

 



In this tutorial, learn how to calculate fillable PDF forms using Adobe Acrobat X or XI. Follow these steps to set calculations in text fields and drop-down boxes that appear in your fillable PDF forms:

To add text fields

  1. Double-click the field where you want to display the result to open the Properties dialog box.
  2. Click the Calculate tab.
  3. To add the values entered into fields, click the Value Is The radio button.
  4. Pick Sum from the popup menu.
  5. Click Pick to open a list of the fields in your form, select the fields you want to add, and click OK to list the fields in the dialog box.

To multiply values

  1. Double-click the field where you want to display the result to open the Properties dialog box.
  2. Click the Calculate tab.
  3. To multiply the values entered into fields, click the Value Is The radio button.
  4. Pick Product from the popup menu.
  5. Click Pick to open a list of the fields in your form, select the fields you want to multiply, and click OK to list the fields in the dialog box.

Subtraction and division are a bit harder since you don't have a simple option to pick.

To subtract one field from another

  1. Open the Properties for the results field.
  2. Click the Calculate tab.
  3. Now click the Simplified Field Notation radio button.
  4. click Edit to open the Javascript Editor.
  5. Type the expression in the editor, such as Field1-Field2. Make sure not to add any spaces.
  6. Click OK and you'll see the expression show on the dialog box.

To divide two fields

  1. In the Calculate tab for the results field, choose Simplified Field Notation, and click Edit.
  2. In the JavaScript Editor, type FieldB/FieldA. Again, make sure you don't have any spaces. Click OK and you'll see the expression on the Properties dialog box.
  3. Click Preview to toggle the Preview mode to test your work. You won't have any surprises with adding, subtracting, or multiplying, but a division calculation can cause display problems.

If you leave the default settings for the field as unformatted content, the field shows NaN—which means Not a Number. If you open the Format tab and choose Number from the Format category, you'll see an error message. The only way to guarantee a seamless division operation is to use a JavaScript IF statement to define conditions for the field when it's blank. Unless you write the JavaScript, leave the field unformatted as Acrobat will still calculate the proper value.

So now your form not only looks great, it also gives you and your users immediate information.


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.

Products covered:

Acrobat XIAcrobat X

Related topics:

PDF Forms

Top Searches:

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