0
Javascript for PDF form calculation
New Here
,
/t5/acrobat-discussions/javascript-for-pdf-form-calculation/td-p/10347077
Jan 17, 2019
Jan 17, 2019
Copy link to clipboard
Copied
Hi, I'm new to PDF forms and need to insert a calculation into a form. I've mastered the basic calculations, but need a custom calculation for this one. Can any one help me with it? Here's the formula from excel:
=50+((10*SUM(A1:A10))/(SQRT(0.7*SUMSQ(B1:B10)+0.3*(POWER(SUM(B1:B10),2)))))
Any help greatly appreciated.
John
TOPICS
PDF forms
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more
Community Expert
,
LATEST
/t5/acrobat-discussions/javascript-for-pdf-form-calculation/m-p/10347078#M133572
Jan 17, 2019
Jan 17, 2019
Copy link to clipboard
Copied
There's no one-to-one conversion from Excel to Acrobat JS.
Some functions (like SQRT) do have a direct JS equivalent (Math.sqrt), others (like SUM) don't and you'll need to write your own code to achieve the same result.
See:
https://acrobatusers.com/tutorials/how-to-do-not-so-simple-form-calculations
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting.
Learn more

