cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Helper IV
Helper IV

Upload file to SharePoint from PowerApp and send email with link to this file

Hello.

I am using this instruction to upload files to SharePoint document library with using a flow.

 

https://www.youtube.com/watch?v=5XsWgVnR7SU 

 

And I need to send a link to this file, which I have just uploaded.
I am trying to use Last(Contracts).'Link to item' in email body, but it works time to time, and sometimes it is not last file from my library.
I need to send a link to a file which I have just uploaded.

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted

@ppl 

 

Use "respond to powerapps" action in your flow and pass the URL back to powerapps.

 

View solution in original post

7 REPLIES 7
Highlighted
Resolver II
Resolver II

Hi @ppl ,

 

in the flow after the "create file" action you could add a Send Mail action. Note sure what you get as a response from "create file" but if there is no URL to the file you probably need to add an action "get file properties" and use the ID from the "create file" response to receive the properties. This action will contain a URL to the document in the response. 

Highlighted

@PowerRanger 

I need to get this link on the next screen in my app after uploading, not in flow, because I need to enter email of the person who must get this link.

Highlighted

@ppl 

 

Use "respond to powerapps" action in your flow and pass the URL back to powerapps.

 

View solution in original post

Highlighted

@ppl 

 

As mentioned before you need to add a action "respond to powerapps or flow".  Add a Text Output and name it "urlNewFile" and use the Path responce from the create file action.

 

In PowerApps you need to call your flow like this

Set(myResponse,power.Run().urlNewFile)

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

Highlighted

SharedScreenshot.jpg

If I am trying to use respond to powerapps there is an error

Highlighted

@ppl 

 

You can't place a respond to powerapps action in a ForEach Loop. In this case you need to create an aaray variable before the ForEach action. Within the ForEach you need to add the response from create  file to the array.

 

After the ForEach Loop you add a respond action and pass the array back to powerapps.

Highlighted

@PowerRanger 

What action you mean response from create  file to the array? I made like this and see the same error.

And what value I need to put in Respond To Powerapp value?Screenshot 2020-10-26 171823.png

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

News & Announcements

Community Blog

Stay up tp date on the latest blogs and activities in the community News & Announcements.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Community Highlights

Community Highlights

Check out the Power Platform Community Highlights

Top Solution Authors
Top Kudoed Authors
Users online (7,876)