cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
khanhmekong
New Member

Flow to decline back-to-back meeting

Hi,

 

I would like to create a flow that connect to O365 Outlook Calendar and do the followings:

- Whenever a new meeting is received.

- Check if that meeting is back-to-back with existing meeting which is prior or after the new meeting, meaning: there is no gap between the new meeting with meeting before or after it.

- If it is back-to-back then decline the new meeting with message "You have to leave gap between meetings"

 

How can I do this with Power Automate?

 

Thanks,

1 ACCEPTED SOLUTION

Accepted Solutions
v-yiwenxie-msft
Microsoft
Microsoft

Hi @khanhmekong 

 

You could try to use Filter Query to get those events whose start time is greater than or equal to the start of the day of the start time of the newly-created event.

3.5-17.PNG

Filter Query:

Start/DateTime ge '@{startOfDay(triggerOutputs()?['body/start'])}'

 

For more info about filter query:

OData comparison operator reference - Azure Cognitive Search | Microsoft Docs

 

Best Regards,
Community Support Team _ Kira Xie
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

4 REPLIES 4
v-yiwenxie-msft
Microsoft
Microsoft

Hi @khanhmekong 

 

You could try the flow as below:

3.4-4.PNG

The dynamic content 'value' for 'Apply to each' is from 'Get events'.

The dynamic content for the left side 'Start time' and 'End time' is from 'Get events'.

The dynamic content for the right side 'Start time' and 'End time' is from 'When a new event is created'.

 

If you still have the problem, please feel free to let me know.

 

Best Regards,
Community Support Team _ Kira Xie
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

khanhmekong
New Member

Hi @v-yiwenxie-msft ,

Thank you for the flow, I think it can do what we need.

I have question about step 'Get events': Could you guide me how to filter only events of the booking day? Because I think we don't need to get all events of the calendar.

 

Flow to decline back to back meeting.png

v-yiwenxie-msft
Microsoft
Microsoft

Hi @khanhmekong 

 

You could try to use Filter Query to get those events whose start time is greater than or equal to the start of the day of the start time of the newly-created event.

3.5-17.PNG

Filter Query:

Start/DateTime ge '@{startOfDay(triggerOutputs()?['body/start'])}'

 

For more info about filter query:

OData comparison operator reference - Azure Cognitive Search | Microsoft Docs

 

Best Regards,
Community Support Team _ Kira Xie
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

khanhmekong
New Member

Hi @v-yiwenxie-msft ,

 

The flow works very well. Thanks a lot for your help!

 

Best,

Helpful resources

Announcements
Process Advisor

Introducing Process Advisor

Check out the new Process Advisor community forum board!

MPA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

MBAS Attendee Badge

Claim Your Badge & Digital Swag!

Check out how to claim yours today!

Users online (73,796)