Timezone Amsterdam here.
I have a task where files are being generated with timestamps in the content, including UTC, see here:
<Schedule serviceIDRef="RFLE" start="2026-10-11T06:00:00+02:00" end="2026-10-12T06:00:00+02:00">
However, these files are generated 30 days up front. So, in the meantime, UTC can be +1 instead of +2 despite on the day of generation it's still +2 (summer).
I need some kind of script which checks for yyyy-mm-dd if UTC+1 or UTC+2 is applicable for that date. I have it working now in Powershell, but I'm just woundering if Robotask has some kind of native solution because I notice that this powershell script is delaying the task quite and the task should run as fast as possible. As said: it works now, it's just curiousity.
Code: Select all
# Vaste datum instellen
$datum = [datetime]"{DateTimeToFormat({DateIncDays({PERIOD_START})},yyyy-mm-dd)}"
# Tijdzone Amsterdam
$tijdzone = [System.TimeZoneInfo]::FindSystemTimeZoneById("W. Europe Standard Time")
# Bepaal de tijdzone op basis van de opgegeven datum
$zomertijd = $tijdzone.IsDaylightSavingTime($datum)
if ($zomertijd) {
Write-Output "02:00"
}
else {
Write-Output "01:00"
}