Remote Event Receiver Troubleshooting in SharePoint 2013

Introduction

When an app for SharePoint project in Visual Studio includes a remote event receiver (RER) or an app event receiver, you have to do some additional quick configuration in the project properties before you can debug the app with F5. This configuration, in turn, requires that you do some Azure configuration. You do not have to repeat the Azure configuration for every project that has an RER or app event. (If the app includes an AppInstalled event handler, the app won't even run with either F5 or Ctrl-F5 [run without debugging] unless you carry out the configuration in this section.)

Steps:

  1. Check for error in ULS Log under App Deployment.
  2. Probable error can be-The HTTP request is unauthorized with client authentication scheme 'Anonymous'. The authentication header received from the server was 'NTLM,Negotiate'
  3. Now, insert the following code in your web.config:
    1. protocolMapping>  
    2. <add binding="basicHttpBinding" scheme="https" bindingConfiguration="secureBinding" />  
    3. </protocolMapping>  
  4. Go to IIS, under Authentication set Anonymous Authentication-ENABLED:

    IIS Manager

    Figure 2: IIS Manager

  5. Now Enable Anonymous Authentication in your project as well:

    Anonymous Authentication

    Figure 1: Anonymous Authentication

  6. Deploy the App again and it will work.
Ebook Download
View all
Learn
View all