parsing time changes date

I have a calendar event that is set to a date, lets say 13/feb/2023 if I parse set the variable to 7:00 and run  “parseDateTime($Date_Output, 'HH:mm’)’ it returns: 13 feb 2023 7:00 am perfect but if I change the cal to 21/feb/2023 and run ‘parseDateTime($Date_Output, 'HH:mm')’ it changes the date, and sets the time to 7:00 am   the question is if this is a bug or known behaviour? does parseDateTime change to today's date?      
2 answers

Hi Jason,


parseDateTime converts a string to a date time. formatDateTime converts the Date and time value to a string.


When using the calendar, I assume your $DateOutput is an Attribute of type DateTime. Can you try formatDateTime($DateOutput, ‘HH:mm’ ) HH is 0-23 hh is 0-12  (see here) and the ‘a’ is returning the string am or pm.


Go make it


@marco not sure if this is the best way of doing it, but this is my Frankenstein solution, it works