January 18, 2018

SharePoint app: ‘An error occurred while processing your request’ on Windows 7 and IE11


When deploying a provider hosted app for SharePoint (Online), and you have a button on the app causing normal ASP.NET postback, whenever clicking on the button, you get error “An error occurred while processing your request.”

What is interesting is that the issue only occurs on IE11 on Windows 7. It doesn’t occur on IE11 on Windows 10, for example.


When debugging the SharePoint app at the time of clicking the button and postback, I saw that contrary to when entering the form with Windows7+IE11, there was a SPAppToken Form parameter, but on postback it was gone. Some people had solved it by manually taking the SPAppToken parameter and placing it into a hidden field on the page in order to ensure it was there also during postback.


I finally figured out solution, which didn’t involve any changes in the program code. On IE11 on Windows 7, you need to add the URL of the provider host app into Trusted Sites in IE11.

If app is hosted in Azure, the URL could be something like https://myproviderhostedapp.azurewebsites.net.


  1. I am facing same issue for on premise environment where my apps are hosted in IIS. Do you have solution for that? I have been struggling with this for quite some time now.

    1. I assume you've ensured URL of the provider hosted app is in IE's Trusted Sites list? That was the fix in my scenario, so if that doesn't help, I'd try with different browsers to try to pinpoint if it is broken in all browsers (=not issue with browser, and basically different issue from what I experienced).

    2. you saved my ass after 4 days of struggling with this - thank you - I had re-installed windows and this setting was gone.