Forum Discussion
Not able to save credentials - excel source file in OneDrive
- 1 year ago
Hi Alex0106 ,
Thanks for reaching out to the Microsoft fabric community forum.Get SharePoint Site and File Path
Open the Excel file in OneDrive for Business in the browser.Click "..." - Details to view the document location.
Copy the full SharePoint URL up to the site root.
Example: https://yourorg.sharepoint.com/sites/YourTeamSite
Use SharePoint Folder in Power BI Desktop
In Power BI Desktop, go to Home - Get Data - More - SharePoint Folder.Enter the root SharePoint URL (like above).
When prompted for credentials:
Choose Organizational account (OAuth2).
Sign in with your work credentials.
Power BI will return all files in the site. Filter by your file name to select your Excel file.
Load the Data
Transform the data using Power Query as needed.Save and publish the report to Power BI Service.
Set Credentials in Power BI Service
Go to Power BI Service - Workspace - Dataset Settings.Under Data source credentials, choose OAuth2 / Organizational account and sign in.
Click Save - it should now work properly since SharePoint Folder supports this flow.
If the response has addressed your query, please Accept it as a solution and give a 'Kudos' so other members can easily find itBest Regards,
Sreeteja.
Community Support Team
Hi Alex0106 ,
Thanks for reaching out to the Microsoft fabric community forum.
Step 1: Use the Web Connector with Direct Download Link to Excel File
The Excel connector often restricts auth options. The Web connector supports OAuth2 and is more flexible with OneDrive/SharePoint Online files.
To do this:
Go to your Excel file in OneDrive.
Get the direct download link:
Open the file in OneDrive (in browser).
Click Share - Copy Link (make sure link allows access).
Modify the link to force direct download if needed by replacing
?e=... with ?download=1 or use the OneDrive "Embed" option to extract a direct download URL.
Example-
https://onedrive.live.com/download?resid=FILEID&authkey=AUTHKEY
Open Power BI Desktop.
Choose Get Data > Web.
Paste the direct download URL obtained in step 2.
When prompted for authentication in Power BI Desktop, select OAuth2 and sign in with your organizational account.
Load your data and create your report.
Publish the report to Power BI Service.
Configure Credentials in Power BI Service
Go to Power BI Service > Workspace > Dataset Settings.
Under Data source credentials, click Edit Credentials for your data source.
You should now see OAuth2 as an option select it.
Sign in and save the credentials successfully.
Clean Old Data Source Permissions
In Power BI Desktop, go to File > Options and settings > Data source settings.
Find and clear any existing permissions related to the old Excel or OneDrive source.
Save and republish your report after reconnecting via the Web connector.
Additional Tips:
Use SharePoint URL instead of OneDrive URL if you’re using OneDrive for Business:
OneDrive for Business files are stored in SharePoint. Use the SharePoint site URL and folder path to connect via SharePoint Folder connector or Web connector.
Update Power BI Desktop to the latest version to ensure all authentication features are available.
Check with your IT admin if tenant policies restrict authentication flows.
If the response has addressed your query, please Accept it as a solution and give a 'Kudos' so other members can easily find it
Best Regards,
Sreeteja.
Community Support Team
Hi
Thanks for your response. Unfortunately its still not working.
When I copy the link I can grant access but only to people in my organisation. I can't grant access to anyone who has the link. Could this be the issue?
I also can't find the onedrive embed option in my work onedrive online - I can see it on my personal onedrive files.
- v-sshirivolu1 year agoCommunity Support
Hi Alex0106 ,
Thanks for reaching out to the Microsoft fabric community forum.Get SharePoint Site and File Path
Open the Excel file in OneDrive for Business in the browser.Click "..." - Details to view the document location.
Copy the full SharePoint URL up to the site root.
Example: https://yourorg.sharepoint.com/sites/YourTeamSite
Use SharePoint Folder in Power BI Desktop
In Power BI Desktop, go to Home - Get Data - More - SharePoint Folder.Enter the root SharePoint URL (like above).
When prompted for credentials:
Choose Organizational account (OAuth2).
Sign in with your work credentials.
Power BI will return all files in the site. Filter by your file name to select your Excel file.
Load the Data
Transform the data using Power Query as needed.Save and publish the report to Power BI Service.
Set Credentials in Power BI Service
Go to Power BI Service - Workspace - Dataset Settings.Under Data source credentials, choose OAuth2 / Organizational account and sign in.
Click Save - it should now work properly since SharePoint Folder supports this flow.
If the response has addressed your query, please Accept it as a solution and give a 'Kudos' so other members can easily find itBest Regards,
Sreeteja.
Community Support Team
- Alex01061 year agoRegular Visitor
Thank you!!
For others - i had /:x/r/ in the site root URL - no idea why. I just deleted them so that the root site reflected the format of the example provided and it appeared to work up until loading to the desktop version where the connection broke down (so the connection was working in power query but then the data wouldnt load in Power Bi desktop view).
After some googling, turning off Internet Protocol Version 6 (TCP/IPv6) in the wifi settings seemed to fix the issue and I now have the connection and can set up an automatic refresh in Power Bi Service.