Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics CRM forum
Suggested answer

Export Dynamics 365 emails out as EML files using Flow/Power Automate

Posted on by 2,066

Hi guys,

Quick question. I've read a article on how to export office 365 Outlook emails and use it to create a EML file in Sharepoint.

www.oneplacesolutions.com/.../save-important-emails-to-sharepoint-with-microsoft-flow.html

Basically it looks like the Flow for Outlook has a Export email action in flow which you can then put the body into the sharepoint file. 

pastedimage1618307074570v1.png

pastedimage1618307137859v2.png

My question is whether it's possible to do the same with a Dynamics 365 Email. Either sent or received.

I've found alot of articles online on moving email attachments but none on how to save the actual email itself.

Kind regards,

Mike

  • Suggested answer
    Ian McV Profile Picture
    Ian McV 10 on at
    RE: Export Dynamics 365 emails out as EML files using Flow/Power Automate

    Mike,

    Not sure if you have ever found a solution for this one, but I have the same requirement today and put the following solution in place.  It is working for me (so far).  Thought you may be interested.

    1. Set a string variable and format the Date Sent (I just used the Created On field as Sent Date doesn't always appear to be updated).

       formatDateTime(outputs('Get_a_row_by_ID')?['body/createdon'],'ddd dd MMM, yyyy hh:mm')

    2. Use the Compose action to re-create the email body (refer to the screen shot below for detail)

    3. Create your new .eml file using the Output from the Compose action.  I used the Create OneDrive file for testing.

    You should then be able to open the eml file using Mail or Outlook.  I am not needing the attachments as I am storing these separately, but if you do you may need do a little more investigating.

    Screenshot-2022_2D00_05_2D00_25-185419.png

Helpful resources

Quick Links

First Dynamics 365 Community Call (CRM Edition)

Don't miss the first D365 Community Call on 7/10!

Community Spotlight of the Month

Kudos to Saurav Dhyani!

Congratulations to the June Top 10 community leaders!

These stars go above and beyond . . .

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 285,642 Super User

#2
Martin Dráb Profile Picture

Martin Dráb 225,485 Super User

#3
nmaenpaa Profile Picture

nmaenpaa 101,148

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans