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

Join the FabCon + SQLCon recap series. Up next: Power BI, Real-Time Intelligence, IQ and AI, and Data Factory take center stage. All sessions are available on-demand after the live show. Register now

Reply
nmhung49
Helper II
Helper II

Update Path file automatic when change source file

I get data from multiple files in the same folder, but when I change the path and refresh data, I have a  error message. For example

 

File Path                                                        File Name

D:\OneDrive\2018\                                       A.xls

 

 

                                                                      B.xls

                                                                      C.xls

And the file get data with the path D:\OneDrive\Total.xls

When I changed File of the Path to

D:\OneDrive\2018\Data\                               A.xls 

                                                                      B.xls

                                                                      C.xls

And the file get data with the path D:\OneDrive\2018\Total.xls

When I refresh data have an error

[Datasource.error] Could not find file 😧 \ OneDrive \ 2018 \ A.xls ...

Now, I want to automatically update the Path file when I refresh the data

Currently I use fomular excel: Cell ("file name") to get the path to update change part of the path

 

Thanks!!!!

 

1 REPLY 1
v-juanli-msft
Community Support
Community Support

Hi @nmhung49

As searched and tested, it is impossible to refresh the dataset and chane the data source path at the same time in Power BI currentlly.

When you click on "refresh" button, it will refresh the data from the exsiting data source file via data connection.

 

To select different data source files for the report,

You could go to query editor, select your table and on the right hand side under Applied Steps click settings icon.

5.png

 

You can also go to File -> Options and settings -> Data source settings >Right click data sources and change source.

 

Best Regards

Maggie

 

 

 

Helpful resources

Announcements
April Power BI Update Carousel

Power BI Monthly Update - April 2026

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

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

FabCon and SQLCon Highlights Carousel

FabCon &SQLCon Highlights

Experience the highlights from FabCon & SQLCon, available live and on-demand starting April 14th.