0 Replies Latest reply on Jan 4, 2013 7:47 AM by got-questions

    Javascript If statement and Alert Box Help

    got-questions

      I have a form with the following Javascript with If Statement that will generate an alert box. This form is created in Adobe LiveCycle ES 8.2.

       

       

        if ((Field_A.rawValue == 1) || (Field_B.rawValue == 2) && (Field_C.rawValue == 3) {---xfa.host.messageBox("Please select the appropriate fields. } // this code will have an alert message when Field_A is 1, Field_B is 2 and Field_C is 3 ignore the "---" because it wouldn't show the code without add "---".

       

       

       

       

       

       

       

       

       

       

       

       

       

      The problem is that when Field_A is 2, Field_B and Field_C is set to not to display (invisible) because it is not applicable. Is there a way to set if Field_A is 2 and ignore all message box alerts?

      Thanks,

      JW