cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
RoterDrache92
Advocate III
Advocate III

HOW TO ATTACH FILE FROM CDS TO OUTLOOK?

I created a field Upload File to CDS. Once the file is uploaded to this field, it will be attached in the email and send it to me.

RoterDrache92_0-1597375613932.png

I created a flow for this, however, it failed. Please help

RoterDrache92_1-1597376025080.png

RoterDrache92_0-1597377041940.png

 

 

1 ACCEPTED SOLUTION

Accepted Solutions

@RoterDrache92 

Can you paste screen shot for your Get File Item or Image, i have tried the same and the get file is returning data.

Mira_Ghaly_0-1597389516048.png

Mira_Ghaly_1-1597389578597.png

 

 

If this post helps you with your problem, please mark your as Accepted solution.If you like my response, please give it a Thumbs Up.

Blog: here

View solution in original post

7 REPLIES 7
Mira_Ghaly
Dual Super User II
Dual Super User II

@RoterDrache92 

Can you make sure that your Trigger runs on Update because on Create the File will be null.

If this post helps you with your problem, please mark your as Accepted solution.If you like my response, please give it a Thumbs Up.

Blog: here

Hello Mira,

Thank you for your response!

This is the trigger body:

 

RoterDrache92_0-1597388056999.png

{
  "address2_addresstypecode"1,
  "_address2_addresstypecode_label""Default Value",
  "merged"false,
  "statecode"0,
  "_statecode_label""Active",
  "exchangerate"1,
  "name""LOng",
  "opendeals"0,
  "modifiedon""2020-08-14T02:54:04Z",
  "openrevenue_state"1,
  "donotpostalmail"false,
  "accountratingcode"1,
  "_accountratingcode_label""Default Value",
  "marketingonly"false,
  "donotphone"false,
  "preferredcontactmethodcode"1,
  "_preferredcontactmethodcode_label""Any",
  "_ownerid_value""52da0ec2-e1a3-453e-9c2c-5d1733060b7d",
  "_ownerid_type""systemusers",
  "customersizecode"1,
  "_customersizecode_label""Default Value",
  "openrevenue_date""2020-08-14T02:53:11Z",
  "msevtmgt_rentalcarprovider"100000001,
  "_msevtmgt_rentalcarprovider_label""No",
  "businesstypecode"1,
  "_businesstypecode_label""Default Value",
  "donotemail"false,
  "statuscode"1,
  "_statuscode_label""Active",
  "createdon""2020-08-14T02:53:11Z",
  "msdyn_travelchargetype"690970003,
  "_msdyn_travelchargetype_label""None",
  "opendeals_state"1,
  "donotbulkemail"false,
  "openrevenue"0,
  "donotsendmm"false,
  "donotfax"false,
  "donotbulkpostalmail"false,
  "creditonhold"false,
  "telephone1""12333",
  "_transactioncurrencyid_value""0004cbd8-52a8-ea11-a812-000d3aa3e835",
  "_transactioncurrencyid_type""transactioncurrencies",
  "accountid""a0f1cb49-d9dd-ea11-a813-000d3aa3ee47",
  "msevtmgt_hotelgroup"100000001,
  "_msevtmgt_hotelgroup_label""No",
  "_modifiedby_value""52da0ec2-e1a3-453e-9c2c-5d1733060b7d",
  "_modifiedby_type""systemusers",
  "followemail"true,
  "shippingmethodcode"1,
  "_shippingmethodcode_label""Default Value",
  "_createdby_value""52da0ec2-e1a3-453e-9c2c-5d1733060b7d",
  "_createdby_type""systemusers",
  "territorycode"1,
  "_territorycode_label""Default Value",
  "msdyn_taxexempt"false,
  "participatesinworkflow"false,
  "accountclassificationcode"1,
  "_accountclassificationcode_label""Default Value",
  "_owningbusinessunit_value""13f38f3e-3ca8-ea11-a812-000d3aa3e835",
  "_owningbusinessunit_type""businessunits",
  "opendeals_date""2020-08-14T02:53:11Z",
  "ItemInternalId""a0f1cb49-d9dd-ea11-a813-000d3aa3ee47",
  "SdkMessage""Update",
  "RunAsSystemUserId""52da0ec2-e1a3-453e-9c2c-5d1733060b7d",
  "RowVersion""7342743"
}

@RoterDrache92 

Can you paste screen shot for your Get File Item or Image, i have tried the same and the get file is returning data.

Mira_Ghaly_0-1597389516048.png

Mira_Ghaly_1-1597389578597.png

 

 

If this post helps you with your problem, please mark your as Accepted solution.If you like my response, please give it a Thumbs Up.

Blog: here

Thank you for your help. I could run the flow successfully. It seems that I chose the wrong Item ID,

Hello Mira,

However, the problem is that I could not open the attachment (PDF, Excel) as it mentioned that these are not supported format. It seems that I need to you parse Json for that. Can you please check?

@RoterDrache92 

I figured out how this works please do the below after the Get File or Content

Mira_Ghaly_0-1597394766895.png

Add a compose variable as below: 

first(outputs('List_records')?['body/value'])['filename']

Mira_Ghaly_1-1597394825399.png

 

 
 

Mira_Ghaly_0-1597394906027.png

If this post helps you with your problem, please mark your as Accepted solution.

 

If you like my response, please give it a Thumbs Up.

 

MG (Naturally Curious)

 

 

If this post helps you with your problem, please mark your as Accepted solution.If you like my response, please give it a Thumbs Up.

Blog: here

Thank you for your response!

Can you please let me know if you can open the attachment file (PDF)?

I cannot open it.

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

New Ideas Forum MPA.jpg

A new place to submit your Ideas for Power Automate

Announcing a new way to share your feedback with the Power Automate Team.

MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

MPA Licensing.jpg

Ask your licensing questions at the Power Automate AMA!

Join Priya Kodukula and the licensing team, super users and MVPs to find answers to your questions on Power Automate licensing.

Users online (3,884)