Creating Time calculations in Acrobat Pro DC

แชร์
ฝัง
  • เผยแพร่เมื่อ 28 ธ.ค. 2024

ความคิดเห็น • 8

  • @tedpadova7633
    @tedpadova7633  4 หลายเดือนก่อน

    Download the tutorial file from:
    www.tedpadova.com/acro/timeCalcs.pdf

  • @stephanedenis5394
    @stephanedenis5394 4 หลายเดือนก่อน

    Thank you very much :)

  • @antonyroome5222
    @antonyroome5222 หลายเดือนก่อน

    Helpful video, how do I calculate time when it goes beyond midnight?

    • @tedpadova7633
      @tedpadova7633  หลายเดือนก่อน

      Hi Antony. Good question. I should have included it in the video and tutorial file. You need to covert the input values to strings. Use the following code in the result field (Calculate tab):
      var start = this.getField("timeIn").valueAsString;
      var finish = this.getField("timeOut").valueAsString;
      if (start=="" || finish=="") event.value = "";
      else {
      var oStart = start.split(":") ;
      var oFinish = finish.split(":") ;
      var hourDiff = oFinish[0] - oStart[0];
      var minDiff = Math.floor(((oFinish[1] - oStart[1]) / 60)*100);
      if (minDiff

    • @antonyroomey
      @antonyroomey หลายเดือนก่อน

      @@tedpadova7633 Hi Ted, thanks for this. The output im getting is in Decimal rather than minutes. Im struggling to get a time output i.e. 09:00-10:54 = 01:54 and im getting 1.9 as the result. Can you help?

    • @tedpadova7633
      @tedpadova7633  หลายเดือนก่อน

      Hi antony. So sorry. I've worked on this for quite some time. I haven't gotten the code right yet. I'll try to work on it, but not sure if I can get it right.

    • @antonyroome5222
      @antonyroome5222 หลายเดือนก่อน

      @@tedpadova7633 thanks for your efforts. If I work it out I’ll post here!

    • @tedpadova7633
      @tedpadova7633  หลายเดือนก่อน

      @@antonyroome5222 OK. I'll try to spend some time working on it and if I work it out, I'll get back to you.