web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Power Automate - Building Flows
Unanswered

Flow and Azure DevOps

(0) ShareShare
ReportReport
Posted on by

Hi, I'm trying to get the time spent on a work item. Like, if I activated the user story/task at 15:30 and closed it at 15:44, I would have spent 14 minutes on it. This is what I'm trying to do right now

 

hd2gTrT.png (615×375) (imgur.com)

Q4Iuv4z.png (615×207) (imgur.com)

iew6cXx.png (1036×182) (imgur.com)

 

where is expression in the compose is

div(sub(ticks(formatDateTime('tempo_fechamento', 'h:mm')),ticks(formatDateTime('tempo_abertura', 'h:mm'))),864000000000)
 
and the error I get is
Unable to process template language expressions in action 'Compose' inputs at line '1' and column '14946': 'In function 'formatDateTime', the value provided for date time string 'tempo_fechamento' was not valid. The datetime string must match ISO 8601 format.'.
 
could somebody give me a hint as what to do
I have the same question (0)
  • Pstork1 Profile Picture
    68,271 Most Valuable Professional on at
    Re: Flow and Azure DevOps

    The format for Date time needs to be in ISO 8601 format.  When using FormatDateTime in Power Automate use the built-in format of 'o' for that.  So use this formula instead.

    div(sub(ticks(formatDateTime('tempo_fechamento', 'o')),ticks(formatDateTime('tempo_abertura', 'o'))),864000000000)
  • Community Power Platform Member Profile Picture
    on at
    Re: Flow and Azure DevOps

    I'm still getting the same error 😞

    The flow looks like this iZsFqFW.png (614×634) (imgur.com)

    and at the end I'm just sending a message in the Teams app

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Chiara Carbone – Community Spotlight

We are honored to recognize Chiara Carbone as our Community Spotlight for November…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 666 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 382 Moderator

#3
developerAJ Profile Picture

developerAJ 254

Last 30 days Overall leaderboard