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

Struggling to connect to a Sharepoint folder

I have been using the local version of the folder, but need to change it to the Sharepoint version for online refreshing.

 

i have a few files that are distint files and that worked fine getting the url and changing from File.Contents to Web.Contents

 

For example this works fine pointing at a single file

 

= Excel.Workbook(Web.Contents("https://cxxxxxxxxltd.sharepoint.com/sites/PowerBIReporting/Shared%20Documents/Trinity%20Data/PowerBI%20Employee%20Export.xlsx"), null, true)

 

I tried to create a new query clicking on new query then Sharepoint folder.  If my source is right at the top of the site I can see a list of files BUT right at the bottom is an error

 

= SharePoint.Files("https://cxxxxxxxltd.sharepoint.com/sites/PowerBIReporting")

 

DataSource.Error: SharePoint: Request failed: The remote server returned an error: (500) Internal Server Error. (An error occurred while processing this request.)
Details:
DataSourceKind=SharePoint
DataSourcePath=https://cxxxxxxltd.sharepoint.com/sites/PowerBIReporting/_vti_bin/ListData.svc/SolutionGallery
SPRequestGuid=9ffaf09f-xxxxxxxxx
Url=https://cxxxxxxxxltd.sharepoint.com/sites/PowerBIReporting/_vti_bin/ListData.svc/SolutionGallery

 

This stops me doing anything further with the query as cannot even remove the error rows so any idea what this is and how to fix it?

 

Ideally shoudln't I be giving it a path further down the tree or do you have to view every file and then filter on the relevant folder afterwards? The rest of the path to actual folder i want is Shared%20Documents/Trinity%20Data/Transaction%20Data%20V3, but that just errors as above.

 

Really appreicate any advice 

Mike

1 ACCEPTED SOLUTION
masplin
Impactful Individual
Impactful Individual

Found the solution to this. You have to add the ApiVerion

 

....sharepoint.com/sites/PowerBIReporting/",[ApiVersion=15]),

View solution in original post

1 REPLY 1
masplin
Impactful Individual
Impactful Individual

Found the solution to this. You have to add the ApiVerion

 

....sharepoint.com/sites/PowerBIReporting/",[ApiVersion=15]),

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.