cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Frequent Visitor

Calculation with dates in Flow is not working.

Sorry, once again me. Please help me or I will despair. - Thanks in advance.

 

My problem is, that the calculation [Date in SharePoint-column]+10 days = due date in Wunderlist is not working. The result is always the text of my formula "adddays...."

 

Flow1.PNG

 

History of the last run: 

  • Host
    { "api": { "runtimeUrl": "https://europe-001.azure-apim.net/apim/wunderlist" }, "connection": { "name": "/providers/Microsoft.PowerApps/apis/shared_wunderlist/connections/shared-wunderlist-14b1b1f6-c83b-4b9d-9c99-6819b6cb30cb" } }
  • Methode
    post
  • Pfad
    /tasks
  • Authentifizierung
    { "parameter": "*sanitized*", "value": "*sanitized*", "type": "Raw" }
  • Text
    { "list_id": 131869882, "title": "2017-02-22", "due_date": "adddays ('2017-02-22', 10)" }

AUSGABEN
  • Überschriften
    { "X-Current-User-ID": "11790278", "X-Request-ID": "324675435376532", "Cache-Control": "must-revalidate, max-age=0, private", "Date": "Thu, 23 Feb 2017 21:39:26 GMT", "Server": "nginx,Microsoft-HTTPAPI/2.0", "Content-Length": "208", "Content-Type": "application/json
13 REPLIES 13
Highlighted
Anonymous
Not applicable

Re: Calculation with dates in Flow is not working.

Hi skoester

 

Try adding an @-Symbol at the beginning of adddays. It that doesnt help, put the @adddays-Statement in a Value field and then insert that value-field in the "Fälligkeitsdatum".

 

Cheer up,

Georg

Highlighted
Frequent Visitor

Re: Calculation with dates in Flow is not working.

Hi Georg,
@-Symbol is not working , I tried this now for one week in nearly every constellation.
What is a value field?
Stefan
Highlighted
Anonymous
Not applicable

Re: Calculation with dates in Flow is not working.

Hi Stefan

 

in German it's "Verfassen":

 

Flow 3.PNG

 

This is what I use to add 10 days to a date.

Highlighted
Frequent Visitor

Re: Calculation with dates in Flow is not working.

Yes, I tries this also in different ways:

 

Flow2.PNG

 

This is the result:Text and no due date

Unbenannt.PNG

 

 

Highlighted
Anonymous
Not applicable

Re: Calculation with dates in Flow is not working.

I suppose you also tried it with the @? If yes, I'm out of ideas...

 

Sorry,

Georg

Highlighted
Frequent Visitor

Re: Calculation with dates in Flow is not working.

That is my problem.

Since one week I tried in so many ways, with calculated fields in Flow, with calculates columns in Sharepoint - nothings works.

Only the original startdate - without any calculation - works.

Highlighted
Community Support
Community Support

Re: Calculation with dates in Flow is not working.

Hi Skoester,

 

As you are using SharePoint list, may I suggest you create a Calculated column type in the list? So that you can get the Due date from the list.


My steps for a reference.
1. Create a Calculated column type and name it as DueDate.

2.PNG

2.A SharePoint list with StartDate and DueDate looks like below. When a Start Date is entered, the Due Date will be calculated automatically.
3.PNG
3. Then create a flow to create task in Wunderlist when a new item is created in SharePoint list. You can configure the Due Date field from the Dynamic content. Then run the flow, you will find a task will be created in Wunderlist with right Due Date.

4.PNG

 

Hope this could be a reference for you.


Best regards,
Mabel Mao

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Highlighted
Frequent Visitor

Re: Calculation with dates in Flow is not working.

Thanks for your Tip.

Of course I tried this also in different ways, but in that case we will find another problem - dateformats.

The calculated SharePoint-Field delivers a different format than a original date field.

 

 

 

 

Result with a calculated field (due date in Wunderlist): 

Title = Result of the formular, I think Wunderlist expects yyyy-MM-dd as a due date format.

Even with the FormatDateTime-Function I found no way to solve this.

 

flow3PNG.PNG

@v-yamao-msft: Do you have any other idea?

Highlighted
Community Support
Community Support

Re: Calculation with dates in Flow is not working.

Hi Skoester,

 

What due date format do you want? Is it “yyyy-MM-dd”?

 

You said that “The calculated SharePoint-Field delivers a different format than an original date field”. You could configure the format when you create the column in the list.
The Start Date and Due Date are formatted in the same format in my list.

 

Just as I suggested in another post from you, you could configure the date format of your Wunderlist:
https://powerusers.microsoft.com/t5/Flow-Forum/Create-Wunderlist-task-with-due-date-from-new-SharePo...


Best regards,
Mabel Mao

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Highlighted
Community Support
Community Support

Re: Calculation with dates in Flow is not working.

Hi Skoester,

 

Thanks for your detailed private message.

 

I changed the Language setting of my Wunderlist to Deutsch, then when I ran the flow I created before, I got the same result with you, the Calculated column in SharePoint doesn’t deliver the proper format as I have set in my Wunderlist.

 

Then I try to find a workaround, using the Compose function instead of using the SharePoint Calculated column.
I create a flow looks like below, and it works as expected:

2.PNG

1.png

 

Please try to configure the Compose action using the similar function with me, and you should add a Double quotes when configuring it.
Please refer to the following steps:
1. Configure the flow looks like below:

3.PNG

2. Click the button “Create flow”, then you would get an error message looks like below:

4.PNG

3. But please don’t be afraid of the error, just copy the highlighted parts and replace the Dynamic content, then it should be looks like below:

5.PNG

4. Click the button Update flow, then run the flow, you will find that it works as expected.


Please try my steps, hope it will also work on your side.


Best regards,
Mabel Mao

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Highlighted
Frequent Visitor

Re: Calculation with dates in Flow is not working.

Hi Mabel,

 

thanks for your efforts to support me, but for me this is not working.

I tried your way, the behavoiur was as described, the date is in the right format for Wunderlist - but the calculation didn't work.

I tried it several times, with differnt variations of your hint - always the same result: no calculation. Here are two examples (also with and without the (at)-sign:

  • adddays(formatDateTime(triggerBody()?@{item()?['Startdatum']},'yyyy-MM-dd'), -10)
  • @adddays(formatDateTime(Startdatum×​​,'yyyy-MM-dd'), -10)

 

Unbenannt.PNG

 

 x.png

 

 

Highlighted
Community Support
Community Support

Re: Calculation with dates in Flow is not working.

Hi Skoester,

 

Please send me a screenshot of the action “Compose” in your flow. please save it firstly, then reopen it to edit it, then capture the screenshot of the action “Compose”.

1.png

 

I found that the function you are using is different from mine. Have you noticed my step2 and step3? Could you please try again to configure it to the same as mine, I guess it should work.


Best regards,
Mabel Mao

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Highlighted
Anonymous
Not applicable

Re: Calculation with dates in Flow is not working.

WOW thanks - this solution has saved me hours.

 

many thanks

 

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

Tech Marathon

Maratón de Soluciones de Negocio Microsoft

Una semana de contenido con +100 sesiones educativas, consultorios, +10 workshops Premium, Hackaton, EXPO, Networking Hall y mucho más!

Top Solution Authors
Top Kudoed Authors
Users online (5,402)