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

Links to SharePoint from PowerApp not working

I have an PowerApp with a Rich Text field used to submit hyperlinks.  When I click the link from the PowerApps gallery, any link to SharePoint (a site page, a file, an image) receives the error in Picture 1.  All other links work as expected.  If I go to my SharePoint list and click the link on the item, it works as expected.  However, I did notice that beginning of the URL is different from say if I copy the link and put it in an email (Picture 2).SPhelp1.JPGSPhelp2.JPG

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Helper I
Helper I

Re: Links to SharePoint from PowerApp not working

This seems to be a known bug with PowerApps.  I ended up using a Html box and set the Default with a "Substitute" function to replace '/sites/' with 'https://yourdomain.sharepoint.com/sites' and it now works as expected.

View solution in original post

13 REPLIES 13
Highlighted
Community Support
Community Support

Re: Links to SharePoint from PowerApp not working

Hi @michaele124 ,

 

From the preview, we can see that there are <p> and </p> at the beginning and end of link. In HTML script, <p> and </p> mean the start and end of the paragraph. They are automatically generated by rich text editor, and it is a laborious duties to remove them.

So I recommand to use Text input box to submit hyperlinks.

Snipaste_2019-11-26_17-17-45.png

Best regards,

Sik

 

Highlighted
Helper I
Helper I

Re: Links to SharePoint from PowerApp not working

If the <p> is the culprit, why are the only links impacted are those to SharePoint? Any other URL works as expected in the PowerApp, it is just links to SharePoint that have this issue.  If I go to SharePoint and open the item, the link works fine, it is only when accessing the link through PowerApps that it has an issue.

 

Note: These links also do not work as expected within Power Automation (Flow). The HTML is present when attempting to place them in an email.

 

The first version of this app used plain text and I was specifically asked to update it so that hyperlinks could be contained within the text boxes themselves as opposed to separately.

 

I can work around not being able to put videos on SharePoint as there is another host site but what do I do with images if I can't link to SharePoint or a public drive? It seems odd that a PowerApp based off a SharePoint list can't find a folder within the same SharePoint based on what should be a direct link.

Highlighted
Community Support
Community Support

Re: Links to SharePoint from PowerApp not working

Hi @michaele124 ,

 

If you use launch function to open the link, the culprit is these HTML tags, so use PlainText to clear the tags.

If you use hyperlinks to open the link, you can use HTML editor to display the HTML of Rich Text editor.

Annotation 2019-11-27 153330.png

If these don't satisfy your need, please share more screenshot and details with your app.

Best regard,

Sik

Highlighted
Helper I
Helper I

Re: Links to SharePoint from PowerApp not working

Hi @v-siky-msft,

 

I think the solution may be more complicated. As you can see in the picture, the links are within the gallery as part of a bigger text box and some entries contain multiple links.  Currently the text input within the gallery is an HTML input but in order to get the formatting right, there is a Replace formula that is used to remove <p> tags with "(nothing)" to eliminate line breaks.  Where does the Launch function go? I've never used that myself so I wouldn't have added to the app. Would using that make my SharePoint links work since I am already removing the <p>?

 

I don't understand why links to anywhere but SharePoint work fine but SharePoint links do not.

Highlighted
Community Support
Community Support

Re: Links to SharePoint from PowerApp not working

Hi @michaele124 ,

 

Could you copy the link address of hyperlinks in gallery and check if it is the same with the link you entered in the Rich text editor?

How do you get the link of SharePoint sites or image?

I have made a test, and hyperlinks in the gallery can manage to link to the SP image. Please check it:

StoG_10.gif

Note: In your scenario, I think there is no need to remove the HTML tags. The HTML Text can recognize these tags, only the launch function can't.

Best regards,

Sik

Highlighted
Helper I
Helper I

Re: Links to SharePoint from PowerApp not working

@v-siky-msft 

When I copy the link using the same process you used in the video, the link is pictured in picture PAhelp4.

 

However, after I submit my form, navigate back to the gallery, and select the item I just created, the link window is changed to "other" and the link is shortened (PAhelp3).

 

Just to make sure it wasn't something I inadvertently did in the app I forgot about, I tried creating a brand new app and the same issue occurred.

Highlighted
Community Support
Community Support

Re: Links to SharePoint from PowerApp not working

Hi @michaele124 ,

 

Is there any formulas applied to HTML Text of RichTextEditor?

Could you please reproduce your steps?

Since this function works fine on my side, I need more details to try to reproduce your issue.

Also I suggest you to have a test in the new canvas app, and use HTML Text control to show the RichTextEditor's HTML text to avoid influence of other factors. 

Snipaste_2019-12-02_14-30-39.png

Best regards

Sik

Highlighted
Regular Visitor

Re: Links to SharePoint from PowerApp not working

@v-siky-msft -  I am having the similar issue with Rich Text editor in PowerApps. All external links copy and paste in the rich text editor are working fine. However, if I copy and paste any link from our SharePoint online site, it's not working. 

 

Looks like the domain name in the link is changed from "mytenantname.sharepoint.com" to   "us.create.powerapps.com"

 

See attached screenshot. 

Highlighted
Helper I
Helper I

Re: Links to SharePoint from PowerApp not working

This seems to be a known bug with PowerApps.  I ended up using a Html box and set the Default with a "Substitute" function to replace '/sites/' with 'https://yourdomain.sharepoint.com/sites' and it now works as expected.

View solution in original post

Helpful resources

Announcements
Ignite

Microsoft Ignite

This will be a conference that you do not want to miss!

secondImage

New Return to Workplace

Reopen responsibly, monitor intelligently, and protect continuously with solutions for a safer work environment.

August 2020 CYST Challenge

Check out the winners of the recent 'Can You Solve These?' community challenge!

Experience what’s next for Power Apps

Join us for an in-depth look at the new Power Apps features and capabilities at the free Microsoft Business Applications Launch Event.

Check this Out

Helpful information

Featuring samples like Return to the Workplace and Emergency Response Applications

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Top Kudoed Authors
Users online (4,178)