5 Replies Latest reply on Nov 15, 2017 10:03 AM by Thom Parker

    End the setIntervall with clearIntervall

    karstent46661207

      Hello,

       

      I want to create a timer that pop-ups after a specific amount of time.

      The User also should be able to stop the timer and the pop-ups. (by choosing between two Radio Buttons)

       

      My problem is: the pop-ups never stop Can anyone help me? Thanks

       

       

      var timer= 0;

      var Feld = this.getField("Group3").value;

      if (Feld == "1")

      {

                     function DoIt() {

                         app.alert("Sie müssen erst einen Wert eingeben!");}

                        timer = app.setInterval("DoIt()", 50000);

      }

      else

        {

                         app.alert("Gestoppt");

                         app.clearInterval(timer);

      }