Forum Discussion
Flow save failing on popular template due to obscure date format issue
This worked to preserve the correct time for me. But I wonder, will I need to change it when DST comes?
convertFromUtc(convertToUtc(triggerOutputs()?['body/start'], 'Central Standard Time'), 'Central Standard Time')
- SamTechNov 28, 2020Copper Contributor
Any advice will be appreciate with my similar error:
(a) Using Dynamic Content "Event Start Date Time"
Flow save failed with code 'OpenApiOperationParameterValidationFailed' and message 'Input parameter 'item' validation failed in workflow operation 'Create_a_Teams_meeting': The parameter with value '"@triggerOutputs()?['body/start']"' in path 'item/start/dateTime' with type/format 'String/date-time' is not convertible to type/format 'String/date-no-tz'.'.
(b) Expression1 convertToUtc(triggerOutputs()?['body/start'], 'GMT Standard Time')
InvalidTemplate. Unable to process template language expressions in action 'Create_a_Teams_meeting' inputs at line '1' and column '22105': 'The template language function 'convertToUtc' expects its second parameter to be a time zone matching the time zone indicated by the timestamp. The provided value '(UTC+00:00) Dublin, Edinburgh, Lisbon, London' is not valid or does not match the timestamp '2020-11-30T14:00:00.0000000Z'. Please see https://aka.ms/logicexpressions#ConvertToUtc for usage details.'.
- JoeK13FJun 29, 2021Copper Contributor
Did you ever find an answer for this? I'm encountering the exact same issue
- lthomas138Jul 29, 2021Copper Contributor
I was experiencing the same issue. I resolved it by using the 'Convert Time Zone' action on my date field. I just chose the same time zone for both parameters but specified the format to be 'Sortable date/time pattern'. Then I was able to feed the output directly into my next step (Create Teams Meeting). Hope this helps you, too.