Forum Discussion
ccsrtw
9 years agoAdvocate I
DataSource.Error: An IO error occurred while trying to access the file...
I'm trying to create a variable query that outputs the name of the file most recently modified in a certain folder. I actually accomplished this yesterday and the output was successful, but when I re...
- 9 years ago
Hi ccsrtw,
It seems folders exist in SharePoint online, please try the SharePoint Folder data source instead of Folder data source. See:
Best Regards,
Qiuyun Yu
v-qiuyu-msft
9 years agoCommunity Support
Hi ccsrtw,
Would you mind recreating a .PBIX file use the same data source to check if the same issue occurs?
Best Regards,
Qiuyun Yu
ccsrtw
9 years agoAdvocate I
v-qiuyu-msft - I created a .pbix file and copy/pasted the code into a blank query:
let
//Choose folder
Source = Folder.Files("\\PATH"),
//filter out all but Excel files
#"Filtered Rows" = Table.SelectRows(Source, each ([Extension] = ".xlsx")),
//sort in descending order by date modified
#"Sorted Rows" = Table.Sort(#"Filtered Rows",{{"Date modified", Order.Descending}}),
output = #"Sorted Rows"{0}[Name]
in
output
Received an identical error:
DataSource.Error: An IO error occurred while trying to access the file '\\PATH'.
Details:
PATH
Really odd. Frustrating that this worked initially and now isn't for no apparent reason!
Again, appreciate all of your help.