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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
js15
New Member

Python filenotfound error in Power BI

I am trying to link a excel file in OneDrive to my Python Script in Power BI. I tried doing it through the onedrive website, but it says filenotfound. Is there any way to fix this issue? (This is using the website, not the Desktop).

js15_0-1738095185778.pngjs15_1-1738095213764.png

 

3 ACCEPTED SOLUTIONS
nilendraFabric
Solution Supplier
Solution Supplier

Hello @js15 

 

Not sure if you have done this, please try this 

 

Go to the location on OneDrive where the excel is saved.

Click on the three dots next to the file name > Details

In the pane on right; click "more details"

You should see "Path" with some squares, you can click that it will copy the location of the file.

In PBI; just do a web source and paste that path as the URL

 

or 

 

Open the Excel file in OneDrive
• Go to File > Share > Embed
• Copy the embed code and extract the URL

 

 Then try this

 

import pandas as pd

url = "https://onedrive.live.com/download?resid=YOUR_RESID&authkey=YOUR_AUTHKEY"
df = pd.read_excel(url)

 

see if this helps

 

Thanks

View solution in original post

Hello @js15,

 

Thank you for bringing your concerns to our attention. We also appreciate @nilendraFabric  for providing a solution. However, we apologize that the provided solution did not resolve the issue. Please consider raising a Microsoft support ticket using the link below:

https://learn.microsoft.com/en-us/power-bi/support/create-support-ticket
 

 

If this helps, kindly accept it as a solution and give a "Kudos" so other members can find it more easily.

Thank you.

View solution in original post

Thank you., I was able to fix it through by just uploading the files to the resources tab on the left side, you can also do it through a lakehouse as well. Thank you so much for the help!

 

View solution in original post

4 REPLIES 4
nilendraFabric
Solution Supplier
Solution Supplier

Hello @js15 

 

Not sure if you have done this, please try this 

 

Go to the location on OneDrive where the excel is saved.

Click on the three dots next to the file name > Details

In the pane on right; click "more details"

You should see "Path" with some squares, you can click that it will copy the location of the file.

In PBI; just do a web source and paste that path as the URL

 

or 

 

Open the Excel file in OneDrive
• Go to File > Share > Embed
• Copy the embed code and extract the URL

 

 Then try this

 

import pandas as pd

url = "https://onedrive.live.com/download?resid=YOUR_RESID&authkey=YOUR_AUTHKEY"
df = pd.read_excel(url)

 

see if this helps

 

Thanks

Thank you, I was able to fix it through by just uploading the files to the resources tab on the left side, you can also do it through a lakehouse as well. Thank you so much for the help!

 

Hello @js15,

 

Thank you for bringing your concerns to our attention. We also appreciate @nilendraFabric  for providing a solution. However, we apologize that the provided solution did not resolve the issue. Please consider raising a Microsoft support ticket using the link below:

https://learn.microsoft.com/en-us/power-bi/support/create-support-ticket
 

 

If this helps, kindly accept it as a solution and give a "Kudos" so other members can find it more easily.

Thank you.

Thank you., I was able to fix it through by just uploading the files to the resources tab on the left side, you can also do it through a lakehouse as well. Thank you so much for the help!

 

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

Jan NL Carousel

Fabric Community Update - January 2025

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