These forums are now Read Only. If you have an Acrobat question, ask questions and get help from one of our experts.

What is wrong with my script?

dablo81
Registered: May 1 2008
Posts: 10

Hi,

I am trying to complete a form in acrobat, but this is the first time I have ever used javascript. Using this forums page, google (and my knowledge of Maths and excel), I have managed to write script for most of the calculations I am performing. However, I am having trouble with the final calculation and would like someone to have a look and offer me some guidance on where I am going wrong. Here is an overview of what I am trying to do, followed by the script:

Overview. I want my calculation to look at the field value in one field (MandateType) and then based on that, look at the value of a second field (“Fund” in 1st field, it looks at FundPercen field, “Segregated” in 1st field, it looks at SegPercen field). Then, based on the value in either FundPercen or SegPercen, my calculation field is to put one of three messages forward (accept, discuss, or fail).

I couldn't post the code, so could someone provide some guidance on how I can complete this calculation?

Can someone tell me where I am going wrong?
Many thanks

try67
Expert
Registered: Oct 30 2008
Posts: 2398
Is this your post as well? http://forums.adobe.com/thread/678620
If so, then there are a lot of things wrong with your code. I would follow the advice you got there.

- AcrobatUsers Community Expert - Contact me personally at try6767 [at] gmail [dot] com
Check out my custom-made scripts website: http://try67.blogspot.com

dablo81
Registered: May 1 2008
Posts: 10
Yes, I posted my query on a few websites. However, I have resolved the problem now. As a complete novice in JavaScript, rather than creating a long Script in just one field, I broke down the calculations into several fields and pointed the fields where necessary. Although laborious, it got me the results I wanted. Thanks to all that helped or looked into helping me.
David