cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
nhafala
Level: Powered On

Gmail reply sent twice

Hi

 

I have a flow that sends an out of office reply when events with certain titles are active in my  calendar.

 

screencapture-emea-flow-microsoft-manage-environments-Default-c26d8596-66d7-4df4-a454-d2b749816fd2-flows-5f217189-cedb-41ef-8242-90a39e667143-2018-12-03-08_47_42.png

 

Everything works fine, except for 1 thing: the flow sends a duplicate reply.

 

I have some dynamic content on the body of the email. Namely, the date I'll be back in the office. I get this date from the end of the calendar event which I then format using compose functions.

I noticed that usually one of the emails is sent with one date format and the other is sent with another.  One uses dd-mm-yyyy and the next one uses yyyy-mm-dd, for example. Sometimes it even sends the unformatted date, which looks like this 2018-12-02T22:59:00+00:00.

 

What do you think the problem is?

3 REPLIES 3
Community Support Team
Community Support Team

Re: Gmail reply sent twice

Hi @nhafala,

 

From the screenshot, it seems that you have two conditions, could you share the functions that are used? It cannot be seen clearly.

I am wondering that if the condition filter out two events that matched the condition, so the reply to email works twice.

Please share more details to help reproduce this issue.

 

Best regards,

Mabel

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.
nhafala
Level: Powered On

Re: Gmail reply sent twice

The first condition expression is: 

 

@and

    (

     greaterorequals(triggerBody()?['DateTimeReceived'], items('Apply_to_each')?['start']),

     lessorequals(triggerBody()?['DateTimeReceived'],items('Apply_to_each')?['end'])

       )

This checks if the current time matches the time of the ongoing event.

 

 

 

 

 

The second condition is:

 

@or(contains(items('Apply_to_each')?['summary'], 'Emanuel frei'),contains(items('Apply_to_each')?['summary'], 'Emanuel frei'))

 

This checks the title of the event.

 

These are the compose functions:

495JF

 

 

Compose 3 has this expression:

addHours(outputs('Compose'),+2)

This adds to hours so the end of certain events fall on the right day.

 

 

 

Compose 2 has this:

formatDateTime(outputs('Compose_3'),'dd-MM-yyyy')

This formats the calendar date.

 

 

 

 

I hope the explanation is clear.

 

nhafala
Level: Powered On

Re: Gmail reply sent twice

Sorry, I think I wrote a new message instead of replying to you. Just in case you weren't notified.

Helpful resources

Announcements
firstImage

Microsoft Business Applications Virtual Launch Event

Join us for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

firstImage

Watch Sessions On Demand!

Continue your learning in our online communities.

Power Platform 2019 Release Wave 2 Plan

Power Platform 2019 Release Wave 2 Plan

Features releasing from October 2019 through March 2020

thirdimage

Flow Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

fifthimage

Microsoft Learn

Learn how to build the business apps that you need

sixthImage

Power Platform World Tour

Find out where you can attend!

seventhimage

Webinars & Video Gallery

Watch & learn from the Flow Community Video Gallery!

Top Kudoed Authors
Users Online
Currently online: 53 members 4,674 guests
Please welcome our newest community members: