简体   繁体   中英

Upload attachments to SharePoint in Dynamics CRM 2015 online

I have a use case where I am building an internet facing asp.net web form for a user to submit a new record to CRM. This web form links to a CRM online instance, which is integrated to a SharePoint online instance. The user that logs into CRM, has access to SP as well.

As part of this new record, I also want to give them the ability to add an attachment, and have that attachment go directly into the SharePoint document library/server that is linked to the CRM instance.

I can see some SharePoint entities listed in the SDK like SharePointData, SharePointDocument, DocumentLocation, and Site, but cannot find any sample code on how to use them, or how to get a file into SP via the SDK?

Any xRM examples out there that I could use?

If you're working with you're own internet facing asp.net web form, you can also upload the file to SharePoint directly. You just need to have the location to store the file. And I assume you can get that from CRM.

You have two options:

  1. Using the SharePoint rest endpoint
  2. Or use the SharePoint.Client assembly.

This is the MSDN article for SharePoint online: https://msdn.microsoft.com/en-us/library/office/dn904536.aspx

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM