Copy link to clipboard
Copied
I've created a form where our technicians can select one of three boxes for courses they are required to take. Depending on the box they select a field will either populate with $0 or a specific dollar amount. I now want to add the fields with the dollar amounts and I can't get adobe to do that for me.
Here is the sample script I'm using based on something I found online: event.value=this.getField(“Text37”).value+this.getField(“Text38”).value;
It's not wrking. Any help would be greatly appreciated.
Sounds like the file got corrupt. Did you at any point edit the scripts via the Edit All JavaScripts command?
Copy link to clipboard
Copied
Use this:
event.value=Number(this.getField("Text37").value)+Number(this.getField("Text38").value);
Copy link to clipboard
Copied
PS. Or you can simply use the built-in Sum command in the Calculate tab and then select Text37 and Text38 from the list...
Copy link to clipboard
Copied
I tried using both, but what happens is when I click “okay” after making the selections or entering the script, the box closes and the script or selections disappear as if I never entered anything in the first place…like this:
Thanks,
Janette
Copy link to clipboard
Copied
You can't use both. Either one or the other.
And if you tried attaching a screenshot it didn't come through. Reply directly from the forum and use the Insert Image icon. Don't attach the image to an email.
Copy link to clipboard
Copied
I can't use either - nothing stays in the boxes so it's impossible to use both at the same time. Here's a picture of what I've entered in the calculation script box and another showing that's disappeared after I click OK. Very frustrating!
Copy link to clipboard
Copied
Sounds like the file got corrupt. Did you at any point edit the scripts via the Edit All JavaScripts command?
Copy link to clipboard
Copied
You're right. I uninstall acrobat then re-installed it - problem solved. It's behaving properly now. Thanks for your help!