Error Handling for "Expression.Error: Access to the resource is forbidden"
This is an Power Query M issue in excel. I combine data from an excel file in sharepoint.
A user changed his connection settings. There was no error message when the user ran his query.
The Error Record does not produce a value (Source[HasError] should produce a boolean value).
let
Source = try SharePoint.Files("https://xxxxxxxxx.sharepoint.com/sites/MHCR", [ApiVersion = 15]),
TestForError = if Source[HasError] then error "There is an error connecting to https://xxxxxxxxx.sharepoint.com/sites/MHCR" else Source
in
TestForError
To test the error, I set the user access to anonymous to force an error:
1 Comment
- v-qiuyu-msft
Community Support
Hi CubedFluidity,
As it's a Power Query issue in Excel, I would suggest you post a new thread in this forum to get help:
https://social.technet.microsoft.com/Forums/en-US/home?forum=powerquery
Best Regards,
Qiuyun Yu