cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Anonymous
Not applicable

Email to calender

Hello All,

 

Brand new here. Need help. 

 

I get the following notification as an email. I wanted to write a flow that extracts information from this email and creates a calender entry in outlook for 30 mins. 

 

email details:

------------------------------------

subject: Proposal Submission for ABC Inc. 

 

Body: 

Hi, 

The Proposal Submission is due on: 

Date: December 18, 2018

Time: 3:00 PM

Thx

------------------------------------

Can someone please help ? I tried split etc, but while everything works to get the data, I am unable to create a new event. 

 

Thanks in advance!! 

 

 

 

 

2 REPLIES 2
Community Support Team
Community Support Team

Re: Email to calender

Hi @Anonymous,

 

Do you want to extract the information from the email body then create an event on Outlook Calendar?

Please take the following configuration for a reference.

By the way, please make sure your email body always contains the info with the same format.

Add the trigger When a new email arrives.

Add the action Html to text.

Add Compose action and enter the following code to get the starting position of the date:

add(indexOf(body('Html_to_text'),'Date:'),5)

Add Compose2, input the following code to get the starting position of Time:

indexOf(body('Html_to_text'),'Time:')

Add Compose3 with the following code to get the extract date info:

substring(body('Html_to_text'),outputs('Compose'),sub(outputs('Compose_2'),outputs('Compose')))

Add Compose4 with the following code to return the extract time info:

substring(body('Html_to_text'),add(outputs('Compose_2'),5),sub(indexOf(body('Html_to_text'),'Thx'),add(outputs('Compose_2'),5)))

Add Compose5 with code to combine date and time:

concat(outputs('Compose_3'),outputs('Compose_4'))

Add Compose6 with following code to format it to an valid time string:

formatDateTime(outputs('Compose_5'),'yyyy-MM-dd HH:MM')

 Add action Create event. Select Email subject for the Subject filed, the output of Compose6 for the Start time field, input the following code for the End time field:

addMinutes(outputs('Compose_6'),30)

 A screenshot for your reference.

1.PNG2.PNG

 

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.
Anonymous
Not applicable

Re: Email to calender

thnks a lot!!!!! This helps!!!!! It works well now

Helpful resources

Announcements
firstImage

Microsoft Business Applications Virtual Launch Event

Watch the event on demand 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: 179 members 4,596 guests
Please welcome our newest community members: