Call function on change of field not working

Home Forums Classic DFFS Call function on change of field not working

Viewing 5 reply threads
  • Author
    Posts
    • #8911
      jstadick
      Participant

        Trying to see if I can call a function when I change a field value. I have a rule setup on the DFFS form. Rule: If this Trigger DayDiscount Is Changed Call function: showme

        In the Custom JS section of Misc tab, I have:

        function showme(){
        alert(“Hello”);
        }

        the function is not called. What am I doing wrong here?

        Thanks for any help.

        John

        • This topic was modified 9 years, 2 months ago by Alexander Bautz. Reason: Moved to DFFS
      • #8950
        Alexander Bautz
        Keymaster

          Hi,
          What kind of field is “DayDiscount”?

          Alexander

        • #9580
          jstadick
          Participant

            Sorry Alexander, just got back to this one. It’s a numeric field. I’ve tried the same thing on a text field on the form with the same result. It just doesn’t call the function. I know the rule is being hit because if I put the message in the “Alert this Message” part of the rule, it works as expected.

            John

          • #9594
            Alexander Bautz
            Keymaster

              Do you see any errors in the developer toolbar in the browser (hit F12 > Console)?
              If so, post the error here. If not, can you add a screenshot of the rule and the custom code in the Custom JS textarea?

              Alexander

            • #9608
              jstadick
              Participant

                Well, after getting this form upgraded to latest version of DFFS, it works as expected.

                Thanks

                John

              • #9612
                Alexander Bautz
                Keymaster

                  I’m glad you figured it out.

                  Alexander

              Viewing 5 reply threads
              • You must be logged in to reply to this topic.