2

I have following problem. I got two projects, one sharepoint-hosted app and another provider hosted app. Both contain a couple of lists. So far so good.

Now I need the data from the sharepoint-hosted app in my provider-hosted app.

This diagram explains what I need to do:

enter image description here

I have been searching and so far have found nothing. I don't even know if this is possible, even in farm solutions I could only achieve this with moderate effort. I hope someone can shed a little light.

  • Are both Provider-Hosted and SharePoint-Hosted app's AppWebs in the same Site Collection? – Alex Burdin Jan 5 '16 at 15:11
  • as a precaution, I would say no. (really depends on the client) – LeonidasFett Jan 5 '16 at 15:18
  • There's no easy way to access SP-hosted app's AppWeb from outside app itself. That's a lot easier and more maintainable to keep shared lists on HostWeb. The other way is to implement custom WCF service (farm solution) and try to reach SP-hosted AppWeb by enumerating HostWeb's child SPWeb objects and checking SPWeb.IsAppWeb property. But it would be neither fast nor reliable, imho. – Alex Burdin Jan 5 '16 at 16:42

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.