Announcement

Collapse
No announcement yet.

Ajax events validation ...

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Ajax events validation ...

    Hi,

    in a form application, I've add on ajax event on fields DATETO and DATEFROM:

    {DAYS}=sc_date_dif({DATETO}, "yyyy-mm-dd", {DATEFROM}, "yyyy-mm-dd");

    working well if I change something and press to enter or an other field , but when I change DATETO or DATEFROM and click to SAVE button without doing anything other, DAYS still stay unchanged !!

    Thank you for your help
    nacyil

  • #2
    Is normal ... Change will not take effect until an input field will be left. Possibly an ajax event fieldname -> onChange helps ...
    Best regards: - Reinhard -

    I use ScriptCase 8 Enterprise Edition, Version 8.(latest)

    Comment


    • #3
      Try this,

      on field (DATE) with Ajax onchange event (changing an other field, here DAY) and you change the value of DATE and CLIC on SAVE, of course when you clic on SAVE it left the input field (DATE) and change it , but the other (DAY) remain unchanged

      For resolving, you need to add the same code in onValidate Event

      Best regards
      Nacyil

      Comment


      • #4
        I think that SC team must validate events ajax automaticaly when the user clicked button save or in event onvalidate.

        Comment


        • #5
          I did a survey and it has many fields ajax. for my works is much and time. for field each ajax validate again in onvalidate event.

          Comment


          • #6
            Hello,

            What kind of ajax event have you set on DATETO?

            regards,
            Bernhard Bernsmann

            Comment


            • #7
              Hi,

              This is the code in Ajax Events "Dateto" onchange

              {day}=sc_date_dif({dateto}, "yyyy-mm-dd", {datefrom}, "yyyy-mm-dd");

              Best regards

              Comment


              • #8
                Hello,

                Issue reported to our bugs team.

                regards,
                Bernhard Bernsmann

                Comment


                • #9
                  Thanks !!!!!

                  Comment

                  Working...
                  X