Showing results for 
Search instead for 
Did you mean: 
Advocate I
Advocate I

Cannot read property 'location' of null

Cannot read property 'location' of null

Session ID: 8ec98dfa-6c32-3b60-8aaf-9568eeabb52c


I created an App in my default environment. The data source is a sharepoint online list for which all my teammates have admin access to the teamsite. I embedded the App to the teamsite and shared the App as "Can Use" to my teammates but it prompts them to create connection to Sharepoint then finally has an error. The usage experience is very bad!

Community Support
Community Support

Hi Mikki,


Could you show me more details about the data source? What are the column types in the list?

When you configure the app, have you used any functions to get the information about location?

Do all the shared users get the same error message “Cannot read property 'location' of null”?

On which device are they running the app?

I am not able to reproduce this issue on my side. Please help provide more details about the issue.


PS: When the first time shared users open the shared app on their side, they are asked to create a connection to data source using their own credentials. It won’t appear the second time they open the shared app on their side. This documentation could be your reference:


Best regards,
Mabel Mao

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hi Mabel,

Thanks for your reply. The error is not referring to a list column. It is for all shared users who get the error. Not related to specific device as even I embed it to a Sharepoint page, the same error is prompted.

I wonder if the connection to a Sharepoint list is a custom connection for which your link mentioned that "When you share an app that uses a custom connector, it is automatically shared, but users must create their own connections to it.".

I exported the App and imported to the company default environment then ask one user to explicitly go to powerapps web portal to create the Sharepoint connection then go to the page with the App again, this time there is prompt to click Allow for Sharepoint permission. And finally they can access the App! The point is they have access to both the App and the Sharepoint list originally and the App stupidly asked for permission to a list not owned by them and during the process, it failed and prompted an error! Really hope Microsoft would improve the sharing experience. I remember such issue was not there when I test on PowerApps last year. Below are the screen caps for the error.


1. Prompt for Sharepoint Permission

2. View Permissions

3. Clicking sign in then prompt to create connection

4. An error is encountered.

5. Clicked on More for error details.



I'm having the exact same issue with this. The powerapp works for me, but doesn't work for our end user. They have permissions to access the sharepoint site and were also logged into the sharepoint site prior to launching the power app. All connections (including to Office365 connected, but the sharepoint side errored with :-


Cannot read property 'location' of null


Session ID: b31ce39d-63e3-35bd-9da7-314a8a9a2481


The sequence of events mirrored exactly what's been outlined above, which leads me to think that it's an error on the PowerApps side, rather than a set up issue on our side.


I'd appreciate any assistance that you may be able to provide.

Helpful resources

PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

MBAS Attendee Badge

Claim Your Badge & Digital Swag!

Check out how to claim yours today!


Demo Extravaganza is Back!

We are excited to announce that Demo Extravaganza for 2021 has started!

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

Power Apps June 2021

June Power Apps Community Call

Don't miss the call this month on June 16th - 8a PDT

Top Solution Authors
Top Kudoed Authors
Users online (69,140)