I’m trying to setup an evaluator column that pulls out a date from a series of log extracts.
Example File: extract_22_06_2021.log
This is the script I’m using to pull this out and it works ok but the date is in text format when I want it recognised as a date.
logDate = RegEx(name, "extract_(.+).log", "\1");
if (logDate == name)
{
return "";
}
else{
return logDate;
}
If I modify the return value from
return logDate;
to
return logDate As date;
The date in the column is then shown as 01/01/1601 so I’m assuming it’s not recognising it correctly as a date. Should ‘22_06_2021’ be recognised as a date and if not what do I need to do for it to be recognised as a date?