2 Replies Latest reply on Sep 22, 2016 6:19 AM by smizy

    Javascript Text Color Change Not Working On IOS App

    smizy Level 1

      Hello all,

       

      Hoping to find some help regarding an issue I'm having. I have a  javascript running a calculation. If that calculation is off by a certain amount compared to another field it turns the text red. This is working flawlessly on pc and on microsoft tablet. However this is intended to be used on a IPad which it is not performing the task properly. The text changes red but then does not change back to black once the value is corrected. I have a ton of other scripts that are all working fine on IPad, it is just this color issue that is preventing me from finishing.

       

      Here is the script I'm running to change the color:

       

      if (Math.abs(this.getField("CALCULATED_WIDTH").value-this.getField("WIDTH").value)>=.03) {

          this.getField("CALCULATED_WIDTH").textColor = color.red;

      }

      else {

          this.getField("CALCULATED_WIDTH").textColor = color.black;

      }

       

      Hopefully someone can help me out with a solution.

       

      Thanks