Hi,
You can do this by creating two date fields.
In my example I will use "DATE1" for the field that will be populating the current date automatically, and "DATE2" which is the field that I will run my calculation script from.
So first, to insert a script in a field object you need to select the "Prepare Form" tool in order to be able to edit the field properties of any field objects in your PDF. Then right-click on the desired field and select from the context menu "Properties". This will open up the field properties dialogue box.
Go ahead and click on the "Calculate" tab of "DATE1" , you may copy the following script below and paste it in the "Custom Calculation Script Section" as shown in the slide below:
event.value = util.printd("mmmm d, yyyy", new Date());

Then add the following script to the "DATE2" field:
var strStart = this.getField("DATE1").value;
var strEnd = this.getField("DATE2").value;
if (strStart.length && strEnd.length) {
var dateStart = util.scand("mmmm d, yyyy",strStart);
var dateEnd = util.scand("mmmm d, yyyy",strEnd);
if (dateEnd.getTime() < dateStart.getTime() ) {
app.alert("The end date can't be earlier than the start date. This document will close now.!");
this.resetForm(["DATE2"]);
this.closeDoc();
this.dirty = false;
}
}
Let me know if this script(s) meet your intent.