Copy link to clipboard
Copied
I have a working table, where the TOTAL line at the bottom correctly calculates the sum of all the fields above it. This works when you're in one of the fields above it and tab out of that field.
However, when the document opens, I'd like the sum to be done initially. Is this possible?
Thanks!
(p.s. I'm pretty good w/ AEM Designer/Livecycle - Acrobat is new to me...)
Copy link to clipboard
Copied
How does you fill the fields?
Copy link to clipboard
Copied
Copy link to clipboard
Copied
Was the form saved with the wrong TOTAL value?
Copy link to clipboard
Copied
Usually, when you have a form, and add data, the sum would be calculated while you are entering data, so when you save the file and re-open it, the correct value should be shown. Are you adding the data programatically via another application?
In that case, you can trigger a calculation with a document level script: Select to create a document level JavaScript and then remove the function stub that's added by default. Anything you know add will be executed when the PDF file is opened in Acrobat or Reader.
What I would do is create the calculation script as another document level script, which you can call from the field calculation script for your sum field. But, because it's now a separate script, you can call it any time you want (e.g. from your "do this when the file is opened" document level script).
Copy link to clipboard
Copied