1

I'm working with a Remote Event Receiver Add-in in SharePoint Online and when I try to install the Add-in the breakpoint at the HandleAppInstalled(); fires, but when it tries to use ClientContext to call the Installing method it throws an exception and the add-in can't be installed.

enter image description here

The exception as follows:

enter image description here

The Add-in is hosted as a Web App on Azure, and I'm using the Cloud Explorer to debug it. The RER is supposed to be installed at the "Site Pages" library and trigger when a file is checked in.

I've tried:

  • Registrering the Add-in with new client id and secret, in the catalog and updated the values in the project.
  • Updated the framework from v4.6 to v4.7
  • Add-in Events Handle Add-in Uninstalled, and Installed set to True (in properties)
  • The project is set to provider hosted, and the Add-in is connected to the right Web project.
  • Probably more things that I can't think of now haha

enter image description here

I highly appreciate any help or suggestions I can get!

  • Provider hosted apps are notoriously fickle. If there's any chance you can pivot away from this approach and deploy an "app-less" RER feel free to check out my blog on the topic: derekgusoff.wordpress.com/2017/11/08/… – Derek Gusoff Nov 23 '18 at 14:04
  • I'm an idiot, when calling the CheckedInEvent I used "CreateAppEventClientContext();" instead of CreateRemoteEventReceiverClientContext();. Now it works like I expected. Thanks for the reply anyways! – Dogemaster Nov 23 '18 at 19:43

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.