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

downloading attachments from sharepoint

Right now i can click on an edit icon for a gallery item, it pulls up a form, i can add an attachment, and when i submit it returns to the gallery screen and an icon appears indicating there is an attachment for that item. I want to be able to click on that icon and immediately view or at least download the attachment associated with that item in the gallery. The best i can do is link to the sharepoint item that has the attachments allllll the way at the bottom. 😐 Any suggestions?

1 ACCEPTED SOLUTION

Accepted Solutions
v-siky-msft
Community Support
Community Support

Hi @KyleJ ,

 

1. add an icon in the gallery

2. set it visible property:  ThisItem.'Has attachments' 

3. set it OnSelect property: Launch(First(ThisItem.Attachments).AbsoluteUri)

Note: Even though you said you just add an attachment, it can be multiple, so it is a table, we have to use First function to get the first attachments URL.

Snipaste_2020-01-03_15-24-24.png

If you have to open other attachments, you can add pop-up box(gallery) to show all attachments when you click the icon.

1. set OnVisible of screen: Set(Var,false)

2. Set OnSelect of Icon: Set(Var,!Var);ClearCollect(ColAtt,ThisItem.Attachments)

3. Add gallery, set Items property: ColAtt

4. Set OnSelect of Gallery: Launch(ThisItem.AbsoluteUri)

Then, it will be like this:StoG_16.gif

Sik

View solution in original post

2 REPLIES 2
SeanHenderson
Impactful Individual
Impactful Individual

Hi @KyleJ 

I don't believe that would be possible. The attachments control on a form doesn't have any process that you could call on a button, it is a specialized control that handles how it uploads and downloads in the background. You also can't put it on a gallery item, the way you can with other columns. 

---
Please hit the "Accept as Solution" button if my post answered your question! If my post was helpful please consider giving it a "Thumbs Up."

v-siky-msft
Community Support
Community Support

Hi @KyleJ ,

 

1. add an icon in the gallery

2. set it visible property:  ThisItem.'Has attachments' 

3. set it OnSelect property: Launch(First(ThisItem.Attachments).AbsoluteUri)

Note: Even though you said you just add an attachment, it can be multiple, so it is a table, we have to use First function to get the first attachments URL.

Snipaste_2020-01-03_15-24-24.png

If you have to open other attachments, you can add pop-up box(gallery) to show all attachments when you click the icon.

1. set OnVisible of screen: Set(Var,false)

2. Set OnSelect of Icon: Set(Var,!Var);ClearCollect(ColAtt,ThisItem.Attachments)

3. Add gallery, set Items property: ColAtt

4. Set OnSelect of Gallery: Launch(ThisItem.AbsoluteUri)

Then, it will be like this:StoG_16.gif

Sik

View solution in original post

Helpful resources

Announcements
PA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

Power Query PA Forum 768x460.png

Check it out!

Did you know that you can visit the Power Query Forum in Power BI and now Power Apps

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Users online (2,802)