cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
JackNimmo
Level: Powered On

Link to file in Library

Hi,

 

I would like to add a control to a powerapps form that allows you to enter a URL/link to an excel file a separate document library.

 

I used to use something similar in Infopath. You could enter a URL and some text then when you opened the item it allowed you to click on the URL to open the Excel file.

 

Is such a thing possible in Powerapps?

 

Thanks,

 

Jack

5 REPLIES 5
Super User
Super User

Re: Link to file in Library

Hi @JackNimmo

 

In PowerApps, you can use the Launch function to open URLs or apps. Here's a link to the documentation.

 

https://docs.microsoft.com/en-us/powerapps/maker/canvas-apps/functions/function-param

 

JackNimmo
Level: Powered On

Re: Link to file in Library

Hi @timl,

 

I have looked at the launch feature but not sure it will do what I need it to.

 

When the form is being filled out by a user I want them to be able to enter a URL to a file in a Library on the same SharePoint site. Then when viewing the entry later I want users to be able to click on that link and be able to open the file.

 

Hope that makes sense?

 

Jack

Super User
Super User

Re: Link to file in Library

Hi @JackNimmo

 

Hopefully, the following screenshot will give you some idea as to how to use the Launch function.

 

The screenshot beneath shows a standard display form that displays a record with 2 columns - Description and URL. In the label for the URL field, you set the OnSelect property to Launch(URL). With a standard display form, you would need to 'unlock' the form and set the DisplayMode of the label to DisplayMode.Edit. It would also be a good idea to set the hover color of the label to make the label look like a hyperlink. Hope this helps.

 

Launch2.JPG

Community Support Team
Community Support Team

Re: Link to file in Library

Hi @JackNimmo,

 

Could you please share a bit more about your scenario?

Do you create a column within your data source to store the URL that the user typed?

 

I assume that you created a column within your data source to store the URL. I agree with @timl's thought almost.

 

I have made a test on my side, please take a try with the following workaround:1.jpg

 

2.jpg

Note: The URL is a Single line of text type column in my SP list data source.

 

 

Within the DetailForm, unlock the Data card control which includes the URL field.

 

Set the DisplayMode property of the Label control within the above Data card control to following formula:

DisplayMode.Edit

Set the OnSelect property of this Label control to following formula:

Launch(ThisItem.URL)

 

Best regards,

Kris

 

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
JackNimmo
Level: Powered On

Re: Link to file in Library

@timl and @v-xida-msft these both look helpful. Thanks!

 

Will get to try them tomorrow hopefully. I will report back my progress.

 

Jack

Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

Top Kudoed Authors
Users Online
Currently online: 90 members 5,403 guests
Please welcome our newest community members: