cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
MattMannion
Advocate I
Advocate I

Creating task from Form submission ("The request is invalid:\r\nCannot convert the literal '2020-06-17T14:28:33' to the expected type 'Edm.DateTimeOffset'.",)

HI All, 

 

I am trying to create a task from a form submission but cannot seem to get the date format to work correctly. 

 

I have tried using the form submission time as the start date but was repeatedly getting errors, So have now started using UTCnow() instead but even then I cannot get the flow to accept the date format. 

 

create task.jpg

 

addDays(body('Convert_time_zone'), 2)

 

error.jpg

 

{
  "error": {
    "code""",
    "message""The request is invalid:\r\nCannot convert the literal '2020-06-17T14:42:17' to the expected type 'Edm.DateTimeOffset'.",
    "innerError": {
      "date""2020-06-17T13:42:17",
      "request-id""3ec31747-bbf1-4123-b13c-cbdec8bc10de"
    }
  }
}

 

Apologies in advance, I know I am going to be bashing my head on the desk when someone advises what I have done wrong. 

 

Kind regards 

Matt 

 

1 ACCEPTED SOLUTION

Accepted Solutions
MattMannion
Advocate I
Advocate I

HI all, 

 

Realised I was using the UTCnow() fucntion wrong, but also found a much simpler solution for what I need. 

 

time.JPG

View solution in original post

2 REPLIES 2
MattMannion
Advocate I
Advocate I

HI all, 

 

Realised I was using the UTCnow() fucntion wrong, but also found a much simpler solution for what I need. 

 

time.JPG

Hello,

 

Thanks for sharing the scenario and the solution. I can be very helpful for other users in similar situation.

 

 

Helpful resources

Announcements
 WHAT’S NEXT AT MICROSOFT IGNITE 2022

WHAT’S NEXT AT MICROSOFT IGNITE 2022

Explore the latest innovations, learn from product experts and partners, level up your skillset, and create connections from around the world.

Register for a Free Workshop.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

Users online (1,586)