Code: Select all
// Assuming your data field is named 'Datum'
var datum = Field("Datum");
// Check if the 'Datum' field is not empty
if (datum) {
// Split the date into parts
var dateParts = datum.split('/');
// Reformat the date as 'DD-MM-YYYY'
var formattedDate = dateParts[1] + '-' + dateParts[0] + '-' + dateParts[2];
// Set the modified value back to the 'Datum' field
Datum = formattedDate;
}