Format date time

Hi Guys,
I am using API to get some values then stored in parameters, date time is one of them.
For instances, a value I am having
executionStart = 2022-04-06T11:09:57.908Z

I wonder that there is any way to format this date as
hh:MM:ss, dd-MM-yyyy

Hi @phongtranone
There is a step, in an addon (Date-Time Operations), called
Get DateTime object in a specific format.
I hope this is what you are looking for,

Hi @matthijs.risselada,
Thank for your uick answer.
I used the action with its name “Get DateTime object in a specific format”.
It could work fine if I tried with the normal date format.
Yet when I put the format with timezone like 2022-04-06T11:09:57.908Z (yyyy-MM-ddThh:MM:ss.SSSZ),
it is not might compatible.


Hi @phongtranone
Try this
With the T and Z between single quotes.

Seems I got months and minutes confused again.

currentDateTimeValue 2022-04-06T11:09:57.908Z

currentDateTimeFormat yyyy-MM-dd’T’hh:mm:ss.SSS’Z’

expectedDateTimeFormatFormat dd-MM-yyyy hh:mm:ss

result 06-04-2022 11:09:57

It worked when adding the apostrophe.
Thank @matthijs.risselada so so much.

1 Like