I used to this error a lot. I figured out that it was coming from the Office 365 network taking too long to respond or not responding at all to the PowerApps call.
To overcome this in my apps I try to use as little calls as possible to Office 365. What I do is whenever a user opens PowerApps I would gather his Office 365 information in a collection and use it through the app. This would call only once and reduce the probability of failing greatly.
To implement it on the main screen (the screen which opens first when users open the app) I put this function in the OnVisible property:
After anywhere in your App you can always use First(UserProfileCollection).Email, First(UserProfileCollection).DisplayName, etc..
What the function does it first checks if the collection already exists if it does it will not pull the information from Office 365 network again.
Using this I never get the Server return a HTTP error with code 0 error. Before I used to have up to 20 calls to Office365Users in one screen and the Office365 network would just not return all of them.
Hope it helps.
Thanks for the response. We are aware of making less calls as possible. In this case it is one myprofile call that is treated as a variable and used filtering collections.
I am very glad to hear that it is working for you now. I also tried this function on my side, it works as expected.
Check it out!
Fill out a quick form to claim your user group badge now!
Find out where you can attend!
Features releasing from October 2019 through March 2020
The largest Power BI, Power Platform, and Data conference in New Zealand