If, when trying to refresh a PowerQuery, you may get the message ‘Query references other queries or steps, so it may not directly access a data source. Please rebuild this data connection’ and it refuses to continue. In this case it often means that a connection in the Query is looking to an external source which is often on an external network (think Dropbox, Onedrive, Hharepoint etc)
Change the Privacy Settings
To get it to work again you can try the following. Note that you may need to do this on all the computers that use the PowerQuery and redo if you reload/ change your computer.
Access the PowerQuery windows. Below one way to do it by right clicking on any one of the queries and clicking on Edit.
Next click on ‘File’, then ‘Options and Settings’ and choose ‘Query Options’ as per below.
Lastly on the Global part (very important unless you want to do it every time), choose ‘Privacy’ and the ‘Always ignore Privacy Level settings’. If you work in a corporate you may need to get permission from IT.
You should then be able to close the query and when you refresh it will access the required files.
Related
Power Query close and load to greyed out
Solution to PowerQuery Create Connection Only being Greyed Out