cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
sperry1625
Helper V
Helper V

Email Attachments as Links

I have a flow that sends out email notifications as one of it's steps.  In certain circumstances the flow will generate a file that is to be included in the notifications.

This is a multi-part problem...

  1. In one path I need to generate an Excel file that has a single table with one row in it.
  2. In a second path I will generate a flat file.

I have been able to generate the Excel file but have realized that the Excel calls are Asynchronous. And since I need to attach the file to the email notification, as well as to a SharePoint list item, I need to load the content of the file after I create it.  There is a chance that the file will not have completed my updates by the time I load it's contents. To get around this I was considering adding a link to the file in SharePoint instead of physically attaching the file. Thus eliminating the concern of update delays in the file updates. But how do I do that? I know I can embed a URL in the body of the email to the file I created. But how do I add a link to the file in the document library as an attachment in the email notification?

SIDE NOTE: While on the subject, other than putting in a false "Delay" in the flow after I call the Excel Add a Row action, is there any way I can detect that my update was actually completed before I load it's contents?  I tried adding Check In/Check Out but still ran into issues of the content not always reflecting my change.

Second path is easy as I do not have the asynchronous issue.  But how I send the file out needs to be consistent.  So the same question applies, how do I include a link to the file as an attachment?

 

Thanks.

 

-S

1 ACCEPTED SOLUTION

Accepted Solutions
fchopo
Super User
Super User

Hello @sperry1625 

After creating the file, you can add an attachment file and its content when using the "Send an Email (v2)" action:

documentlink.png

 

I tried to use "DocumentLink.url" as Attachment Name, but Outlook filters that file extension, so I used "txt".

Hope it helps!

Ferran

 

Did I answer your question? Please consider to mark my post as a solution to help others.
Proud to be a Flownaut!

View solution in original post

1 REPLY 1
fchopo
Super User
Super User

Hello @sperry1625 

After creating the file, you can add an attachment file and its content when using the "Send an Email (v2)" action:

documentlink.png

 

I tried to use "DocumentLink.url" as Attachment Name, but Outlook filters that file extension, so I used "txt".

Hope it helps!

Ferran

 

Did I answer your question? Please consider to mark my post as a solution to help others.
Proud to be a Flownaut!

View solution in original post

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Users online (2,120)