Hello all, I am a newbie at this so please be gentle ;-) I have no experience at all in Power Automate and just started the learning process on Saturday.
I have a number of columns in a Sharepoint List that contain dates in dd/MM/yyyy format. I want to populate a Word document but the dates returned from the "Get Items" action are in YYYY/MM/dd format. How do I ensure they are entered into the word document in dd/MM/yyyy format. The Sharepoint List (Master Staff) contains a mixture of field types and approximately 20 date field types.
From my research I believe that after the "Get Items" action, I need to add a "Parse JSON" action that will go though the Sharepoint List, identify the date fields and format the dates to the desired dd/MM/yyyy format. Am I correct in this assumpation?
I have used Copilot to generate the code below, but Power Automate will not accept the code. What is wrong with it?
// Loop through each list item
Apply to each (Item in List):
// Loop through each field in the item
Apply to each (Field in Item):
// Check if field is a date
If (Field is Date):
// Format the date
Set Field = formatDateTime(Field, 'dd/MM/yyyy')
Below is a screenshot of the flow
Thank you for any help you can provide
Cliff