2 Replies Latest reply on Jul 26, 2013 2:02 PM by pappas.designer

    JavaScript needed for auto insert of "yesterday's" date

    pappas.designer

      I need to create a feild that reads "Yesterdays" date in "mm/dd/yyyy" form. This document that I am creating is a printout that our office assisantants use to wrap around yesterdays run sheets and totals. So it needs to have the date on the paperwork that it applies to, which would be the previous day.

       

      Not sure if this code can be adjusted to work, but this definitely works for "todays" date:

       

      var fld = this.getField("Date"); fld.value = util.printd("mm/dd/yyyy",new Date());