cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
David2831
Helper II
Helper II

Flow to send email containing link to excel doc in sharepoint, open in desktop client

I am making a flow to sort incoming files into correct folders, and email users that new files have arrived.

 

Users would like the emails to contain links to open the files, so they don't have to hunt through lots of folders.  And because the web version of excel is not very good, we want to open the file in the desktop app.

 

I have tried a few different methods mentioned on other posts, below is the current state of my flow.   This is one branch of a switch, the over all flow is large and is triggered when a file is created in a SharePoint library folder. =

 

David2831_0-1636655288128.png

 

Every time I open the flow to edit, the HTML code gets messed up, but here is a copy paste of the important bits of code = 

 

<A HREF="ms-excel:ofe|u|@{outputs('Daily_Log_file_Prop')?['body/{Link}']}">@{outputs('Daily_Log_file_Prop')?['body/{Name}']}</A>

 

This attempt does give me a clickable link in the email that opens the local excel app, but it opens a blank workbook with the the file name set to the same as the SharePoint file.  Its not actually copying down the file and data.  Very frustrating.  I am testing this with an account with site owner permissions, so I don't think its a security thing.

 

I then read a post that mentioned using "create sharing link for file" so I added that feature to my flow and tried this code =

 

<A HREF="ms-excel:ofe|u|@{outputs('Create_sharing_link_for_a_file_or_folder')?['body/link/webUrl']}">@{outputs('Daily_Log_file_Prop')?['body/{FilenameWithExtension}']}</A>

 

This email link gives an excel error about an invalid command.  So no good here.

 

Could someone offer me some advice on how to accomplish this?

1 ACCEPTED SOLUTION

Accepted Solutions
v-LilyW-msft
Community Support
Community Support

Hi @David2831 

Perhaps you can try to send the file as an email attachment to users, so that the user can directly click the attachment to view the file content.

You can refer to the screenshots below to see if it helps.

vLilyWmsft_1-1636958152312.png

Test the flow.

When a file is created in the folder, a new email with attachment will be sent.

vLilyWmsft_2-1636958276542.pngvLilyWmsft_3-1636958297045.png

Hope the content above may help you.

Best Regards

If my solution helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
v-LilyW-msft
Community Support
Community Support

Hi @David2831 

Perhaps you can try to send the file as an email attachment to users, so that the user can directly click the attachment to view the file content.

You can refer to the screenshots below to see if it helps.

vLilyWmsft_1-1636958152312.png

Test the flow.

When a file is created in the folder, a new email with attachment will be sent.

vLilyWmsft_2-1636958276542.pngvLilyWmsft_3-1636958297045.png

Hope the content above may help you.

Best Regards

If my solution helps, then please consider Accept it as the solution to help the other members find it more quickly.

Ideally I did not want to add more files to our email, but I agree this is probably the best solution available, and the one I will probably go with.

 

Thank you.

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 (2,100)