you may do it with the script below. Suppose the name of floating field is "temp". form1.temp.ui.oneOfChild.border.fill.color.value = "255, 255, 255"; You may change the RGB value as per your requirement.
Replace the function with the one below. It would work then as expected. function toWords(s){s = s.toString();
s =s.replace(/[\, ]/g,'');
if (s != parseFloat(s)) return 'not a number';
var x =s.indexOf('.');
if (x == -1) x = s.length;
if (x > 15) return 'too big';
var n = s.split(''); var str = ''...
I am assuming you have a textfield object with the name numFigure in your form . Then you may call the function from the exit event of numFigure like this: numFigure.rawValue = soDecimal.toWords(numFigure.rawValue); Also, toWords method should return the method output. So, you need to add the follow...
As I stated earlier, you need to optimize your script in the first place. Can you please log a Support case for this, as this is a performance issue and requires deeper investigation. Thanks!
Please replace:for (var i=x+1; istr.replace(/\s+/g,' ');with the following:for(var i=x+1; i<y;i++)str.replace(/\s+/g,' '); It should work then. Thanks for pointing out the syntax error!
You have added the calculation scripts via Designer, but the script is actually being executed by Acrobat plugin when you render the form as PDF in Designer. Also, you would need to optimize your script, as Acrobat can only execute the given scripts in the PDF.