12 Replies Latest reply on Oct 26, 2016 4:57 AM by stevenm8611492

    Problems with searching 60 Fields for String and entering the number 10 into a "BSSB" field; No errors

    stevenm8611492

      Problems with searching 60 Fields for String and entering the number 10 into a "BSSB" field; No errors

       

      function SetBSMarksmanshipFieldValues() { for (var i = 1; i<61; i++) { var CSki = ("CSk" + [i]); var CSkStringValue = this.getField(CSki).valueAsString; if (CSkStringValue.valueAsString == "Marksmanship") { this.getField("BSSB").value = 10; i = 60;}}}

       

       

      if(event.willCommit){if(event.value == "") this.resetForm (["BSSB"]);
      else SetBSMarksmanshipFieldValues(event.value);

      }