Skip to main content
Participant
April 11, 2023
Question

Calculate Future Date - Can I Manually Override?

  • April 11, 2023
  • 1 reply
  • 639 views

In a PDF form I have fields where future dates are being calculated by script. 

Is there a way to allow for a manual override of the automatic date, if the manager wants to shorten the timeframe for the contract?

This topic has been closed for replies.

1 reply

ls_rbls
Community Expert
Community Expert
April 11, 2023

Hi @Dawn Dawn 909 ,

 

Would you mind sharing the script and also state where is it executed from and what type of script (i.e. Custom Calculation Script, Validating Script, etc) ?

 

Participant
April 11, 2023

Hi there,

Absolutely, it is a Custom Calculation Script.

var date= util.scand("mm/dd/yyyy", this.getField("FromDate").value);
date.setDate(date.getDate()-30)
if (this.getField("FromDate").value!="")
{
event.value=util.printd("mm/dd/yyyy",date)
}
else
{event.value=""}