Copy link to clipboard
Copied
Hi, I have three fields like this:
"Date field", "Numbers of Day"s and "Calculate Date fields"
I like to calculate like this: Date field + Numbers of Days = Calculate Date (Excluding Weekend days)
Copy link to clipboard
Copied
This requires quite a complex script. There's a lot of information about this subject here:
https://acrobatusers.com/tutorials/working-with-date-and-time-in-acrobat-javascript
https://acrobatusers.com/tutorials/working-with-date-and-time-in-acrobat-javascript-part-2
https://acrobatusers.com/tutorials/working-with-date-and-time-in-acrobat-javascript-part-3
If you're not interested in developing this script yourself another option is to use one that was already developed for this purpose and just apply the code to your fields. For example, I've developed a script that allows you to do just that, and it even has the option of ignoring weekends and even holidays when adding the days to the original date. You can purchase it from here: Custom-made Adobe Scripts: Acrobat -- Apply Automatic Date Calculation
Copy link to clipboard
Copied
There is not any thing, which i required.
I need a script that Add numbers of days into a date and resultant should be date excluding weekends days
Copy link to clipboard
Copied
The script you want will need to written for your specific form. The linked articles show one way to perform date arithmetic and that is covered in Part 1 of Thom Parker's series about date and time calculations. You might not want to use the number of milliseconds, so consider using the getDate() and setDate methods documented in the MDN JavaScript Reference.
This is a User 2 User forum and the vast majority of responders are providing help for free. They have done similar task to yours and we have all learned form Thom Parker's articles. You might want to reconsider your stance about them.
Find more inspiration, events, and resources on the new Adobe Community
Explore Now