Copy link to clipboard
Copied
Means: Acrobat PDF Fillable Form.
I want to make a TEXT FIELD called "Results" that takes a Value in another (seperate) TEXT FIELD, called "Amount" and multiplies that field it by "5" and then compounds/adds to all previous values...
Example:
Amount is multiplied by 5 (1x5=5; 2x5=10; 3x5=15; 4x5=20, and so on)
Thus if "1" is in the field, the "Results" is 5, but if 2 is in the "Amount" field the "Results" would be 15 (5 + 10), and 3 would be 30 (5+10+15), and so on.
Anyone know how to code this?
Copy link to clipboard
Copied
Try something like this as 'Validate' script of "Amount" field:
if(!isNaN(event.value))
this.getField("Results").value += Number(event.value)*5;