Apply format using JS
I stumbled upon Karl Heinz Kremer's article called: "Apply Standard PDF Form Field Formatting/Keystroke/Validation Events to Fields via JavaScript".
A button runs this fine:
var f = this.getField("Text2");
f.setAction("Format", "AFNumber_Format(2, 0, 0, 0, \"\", true);");
f.setAction("Keystroke", "AFNumber_Keystroke(2, 0, 0, 0, \"\", true);");
But if the fields contained data before the script is ran and if I manually enter the same value, it does not apply the new format.
Can you help?
Martin
