Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
masplin
Impactful Individual
Impactful Individual

connecting to Excel file on Sharepoint using web address

Hi

 

I've got a model working fine using the locla path ot asharepoint excel file, but need ot switch it to the web version to publish. 

 

If i go to sharepoint online and copy the link i get this

 

https://cxxxxxxxxxxxxxxxxxxxltd.sharepoint.com/:x:/r/sites/PowerBIReporting/Shared%20Documents/Agenc... 

 

This just says url invalid. I chopped off the bit after xlsx and get request failed. I took out the :x/r/sites/ and get Web.Contents failed ot get contents form this but with a /$value on the end

 

Oddly if I look at sharepoint the folder is "Power BI Reporting" with spaces but this link has no spaces. Elsewhere ther spaces are replaced with %20.  i tried that and no better

 

So the question is what is the correct syntax to read an excel file  if the local path is U:\Sharepoint\CxxxxxxxxxxxxxxxxxxLtd\Power BI Reporting - Documents\Agency Fee Pattern to Sep20.xlsx

 

Thanks any advice as should be really simple

Mike

1 ACCEPTED SOLUTION
masplin
Impactful Individual
Impactful Individual

Found it sorry. You have to get the url out of excel not out of sharepoint!!!

 

Excel.Workbook(Web.Contents(https://cxxxxxxxxxxxxxxxxxltd.sharepoint.com/sites/PowerBIReporting/Shared%20Documents/Agency%20Fee%...), null, true) works

View solution in original post

3 REPLIES 3
masplin
Impactful Individual
Impactful Individual

Found it sorry. You have to get the url out of excel not out of sharepoint!!!

 

Excel.Workbook(Web.Contents(https://cxxxxxxxxxxxxxxxxxltd.sharepoint.com/sites/PowerBIReporting/Shared%20Documents/Agency%20Fee%...), null, true) works

Hi I am trying to connect to a Excel file in a web page but  I can´t do it, please help.

 

http://portalbissrs.xm.com.co/hdrlg/_layouts/15/WopiFrame.aspx?sourcedoc={B3385EEE-113F-4105-ABD4-9B...

 

My issue was my data was stored in a Sharepoint location and I couldn't work out how to get power BI to conenct ot it. Where is your file being stored?

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.