Microsoft Dynamics CRM support integration with SharePoint that enables you to use the document management capabilities of SharePoint from within Microsoft Dynamic CRM. Adxstudio Portals 7 now supports uploading and displaying documents to and from SharePoint directly on an Entity Form or Web Form in the portal. 

Form Document Display

See also Manage SharePoint documents from within Microsoft Dynamics CRM.

If the form is readonly then the documents will be visible but new documents cannot be uploaded.


Complete the following steps to enable documents to be stored in SharePoint from a form in your portal. These instructions assume you have an existing SharePoint environment that is operational.

  1. Enable document management on entities. Please refer to the following documentation provided by Microsoft.
  2. Edit your portal's web.config file and add a connectionString for your SharePoint environment. Refer to SharePoint Connection String for complete details.
  3. Add the Document Locations sub-grid to an entity's form in the CRM web client.
    1. Login to CRM with a user that has the System Administrator or System Customizer role
    2. Navigate to Settings -> Customizations -> Customize the System
    3. Expand Entities
    4. Select the entity
    5. Under the Communication & Collaboration section, check Document Management
    6. Click Save
    7. Click Forms
    8. Click New or Double Click an existing form to edit
    9. Click Insert tab
    10. Click Sub-Grid
    11. Specify a Name
    12. Under Data Source, select the Entity titled Document Locations (Regarding)
    13. Select the Default View titled Active Document Locations
    14. Click Set
    15. Click Save
    16. Click Publish

If you already have an Entity Form, Web Form, or Managed Form that references this entity's form then the SharePoint document library files will be rendered on the form for edit or readonly forms as well as a control to upload a file that will be displayed for insert forms as well. Documents will be stored within SharePoint.

Entity Permissions

Setting up correct Entity Permissions are required to display forms that contain SharePoint document sub-grids. Start by editing the Entity Form or Web Form Step to Enable Entity Permissions which is the minimum to read documents. To allow document uploads, set the mode to Edit and enable Allow Create If Null. The following example enables permissions on an entity form associated to webpage entities.

WebPage EntityForm

Two entity permission records are required to establish the necessary access to view and upload documents.

  1. Permissions on the entity of the Entity/Web Form
  2. Permissions on the SharePoint Document Location with Parent scope refering to the previous permission record

Create an Entity Permission record specifying the Entity/Web Form entity for the Entity Name. Select a scope and scope relationship that is appropriate to the desired behavior of the form. Enable Read and Append To privileges to allow read access to documents and optionally enable Write privilege to allow document uploads. Ignore the Child Entity Permissions section for now since it will be populated by the next step. The completed entity permission looks like this:

WebPage Documents

Create an Entity Permission record specifying the Document Location entity with Parent scope. Select the Regarding relationship for the Parent Scope Relationship and point the Parent Entity Permission lookup to the previous entity permission record (this populates the Child Entity Permissions of the previous record). The minimum privileges to allow read access to documents are Read, Create, and Append. Include Write for document upload access.

WebPage Document Locations