Copy link to clipboard
Copied
Hello, it is possible to have three diferent fields for month, day & year and create a full date from there in another field?
We have a lot of people that enter always day as a month and I'm trying to avoid mistake and reprocesses.
Copy link to clipboard
Copied
Sure, but what should the merged field show if only the month and day fields are filled in, for example?
Copy link to clipboard
Copied
You could use something like this as custom calculation script of the field where you wish to show full date:
var month = this.getField("Month").valueAsString;
var day = this.getField("Day").valueAsString;
var year = this.getField("Year").valueAsString;
event.value = (month && day && year)? month+"/"+day+"/"+year : "";
This assumes field names are "Month", "Day", "Year" and they all need to be filled to show the full date otherwise the field is left blank.
You could add validations to each field so they only accept numbers, for example for month field allow only 1-12, for day 1-31...etc