I have a SharePoint list where each list item has an associated attachment. I'd like to create a column that displays a hyperlink to open that attachment (they are pdf's). I created a column called "Hyperlink" and set the type to Hyperlink. I used PowerApps to change the Default field of this column to:
Unfortunately the column shows as blank even after attaching a pdf to a list item. When I view the item, I can see the attached PDF and the text of the hyperlink shows up properly. How can I get this to show up properly as a hyperlink in my list view?
Hi @Banker_102 ,
I just tested with below formula and it works:
Insert a Label control inside the data card of Hyperlink column and set its Text property to:
I know you may have your reasons but have you thought about using Launch() to open the attachment. It will then just open it in a separate tab to give them the ability to download it or print it.
I have several that I just put the attachments in a gallery and they can click to download it and they work pretty good. See mine below when they click the document name (a sharepoint attachment) it downloads the pdf for them.
Forgive me for being lost, but where can I 'Insert a Label control' on a column in the List?
I attempted to put in the Custom Formatting, but I'm missing how that JSON should be as well.
Any feedback is appreciated.
Don't want to write to the data source, just to make the link available after attachment is complete.
Attaching file with MS Flow and with row added to List and .pdf attached, want to have a column with a link to attachment as requested above. But I'm missing something.
The example above is a SharePoint List as the data source and is just using the built in Attachments field that is there for each item on the SP List.
Then the gallery is listing the attachments for the item that is selected in the other gallery to the left. Once you select the specific document that is attached you can download or view in the PDF viewer.
You can probably do what you are asking to do if you put in a column that is Multiline and plain text (if you are using a SP List) and put the hyperlink there. I store my signatures in that column and it should work the same. You can use Flow to put that data there...just depends on what you are using to get the document into flow. I haven't done it that why in a long time so I don't remember the specifics right off.
That's where I've been. I can edit the JSON in formatting the column and build a hyperlink with the filename captured in @currentField. Only I can't figure out how to get the ID number for ThisItem available inthe JSON code.
"href": "='https://XXXXXXXXXXXXXXXXXXX.com/sites/Fax-Rich/Lists/Outbound/Attachments/'+ @ItemId + '/' +@currentField + '?web=1'"
I can't tell by looking at this part but basically you need something to "Get Item"...just depends on your trigger and then you could use the "Compose" to create a variable for that item ID or Title or whatever you choose to use.
I'm not sure exactly what you doing with this but from what I have gathered so far I really don't think that using JSON would be needed.
Continue your learning in our online communities.
Next Wednesday, September 18th at 8am PDT
Features releasing from October 2019 through March 2020
Coming to a city near you
Fill out a quick form to claim your user group badge now!
Connect, share, and learn with your peers year-round
Register by September 5 to save $200