Create a custom validation script for this field and use this script:
// get the current value of the filed
var v = event.value;
// try to convert the value to a date using the mm/dd/yyyy format
var d = util.scand("mm/dd/yyyy", v);
if (d == null) {
// try to convert using the mm/dd/yy format
d = util.scand("mm/dd/yy", v);
}
if (d != null) {
event.value = util.printd("mm/dd/yyyy", d);
event.rc = true;
}
else {
app.alert("Please enter a correct date");
event.rc = false;
}
Then remove any formatting that you've applied to this field. You should now be able to enter a date in mm/dd/yy or mm/dd/yyyy format, and have it converted to mm/dd/yyyy.
Karl Heinz Kremer
PDF Acrobatics Without a Net
PDF Software Development, Training and More...
http://www.khkonsulting.com