4 Replies Latest reply on Oct 10, 2008 9:12 PM by (WollombiWombat)

    Problems with {NOW}

      Hello,

      any guidelines using {NOW} default values on form fields??

      I have few forms where i'd like to have the form submit last update to the database. For that I included hidden field that submits date {NOW} as default to "last_modified" field on a table. The field is set to 'date'. Sometimes this works ok, but sometimes on other forms the {NOW} from the default field vanishes or submits nothing. Even when i changed the hidden field to text area, it sometimes prints nothing on the form when loaded. Should it not then produce that current date?

      The update recordsets dynamic value shows the soon to be updated fields value request on the "dynamic value" area. This ok?

      So where lies the the magic in it? Do I need to take black cat on my arms and run naked around a certain barn to make this work? Where does the {NOW} vanish from the default field? Any suggestions if this is mainly my own issue, or do others experience similar issues?

      Anyone?
        • 1. Re: Problems with {NOW}
          Level 1
          Its never worked for me

          put the php date in the hidden form field VALUE (lightning) box
          for date
          for datetime

          submit as text

          atb

          Paul
          • 2. Re: Problems with {NOW}
            Waleed Barakat Level 1
            Hi
            you have to change the field properties to:
            ----------------------------------------
            get value from = Entered Value
            then in the default value enter {NOW}

            so this will be used in the insert and update transactions, and you should submit it as (Date) not text.

            for further help please visit:
            ------------------------------
            http://www.developer-online.com

            Or Contact here:
            ----------------
            http://www.developer-online.com/contact.php
            • 3. Re: Problems with {NOW}
              glensbo Level 1
              Hi.

              Have you tried the mark-up language from Interakt in the form?

              {NOW_DT}

              look for further info here:
              http://www.interaktonline.com/Documentation/MXKollection/045420_interaktmarkuplang.htm

              Regards Henrik
              • 4. Re: Problems with {NOW}
                Level 1
                Kimmo

                When you have a field that you want to be updated on every update of the recosr you need to do this with 2 steps.

                First is the normal Dynamic Form you may have something like the following for your date field:


                This will add the date to the record ON INSERT only.

                To make sure that the date gets CHANGED on an update of the form, you must also apply an Add Transaction Field Server Behavior.

                See the How To from Interakt's MX Kollection documentation here:
                http://www.interaktonline.com/Documentation/MXKollection/#041122_tng_update_record_sb.htm

                Cheers.