Getting the day of the week

1
Hi all, In a microflow I need to determine the day of the week for a certain date. Currently I'm using this expression:    formatDateTime($Date,'E') I'm using the 'E' formatting, since Mendix tells this are the formatting options (if you chose custom datatime format in a datagrid):   However, my variables show the date is formatted as 'Fri':   Anyone an idea how to do this, or is this a bug?   Thanks in advance.  
asked
1 answers
6

Hi Ward,

if you use 'u' you will get an integer between 1 and 7. 1 = Monday and 7 = Sunday.

parseInteger(formatDateTime($Date, 'u'))

 

Hope this helps!

answered