Reputation: 6963
I am using MVC4 and need to access and modify data in a SharePoint site. I found this: http://msdn.microsoft.com/en-us/library/hh147177.aspx
Sample code here: http://code.msdn.microsoft.com/Remote-Authentication-in-b7b6f43c
Very interesting, but the sample code is for Windows Forms and the problem is it opens a windows form to ask for credentials.
What I need is a way to achieve the same thing but in a web app.. sample code for either MVC or web forms would be fine. I can't seem to find anything on the web about this, so does anyone have any ideas?
Upvotes: 0
Views: 1889
Reputation: 6963
Found exactly what I needed here: http://www.wictorwilen.se/Post/How-to-do-active-authentication-to-Office-365-and-SharePoint-Online.aspx
Upvotes: 1
Reputation: 3803
I've built an STS using MVC3 that provides authentication services for SharePoint. This great Paraesthesia article helped me adapt the sample STS starter code to run as an MVC controller.
It's a good place to start. If you have more specific questions I can probably answer those too.
Upvotes: 0
Reputation: 1445
Can you query the SharePoint site using AD authentication? Or is it very remote? If so, you can use the app pool identity to authenticate against the SharePoint web service.
Upvotes: 0