In this blog article, you will learn how the DocumentsCorePack ServerBased functionality can be used to upload a SharePoint document to an email in a workflow. For more information on how to create a workflow, please read this article here.
After creating your new process, you will be provided with the window where you can define the steps of your process.
Step 1: Create Email
First, you have to create an email by using the Create Record-step. Open the drop-down menu and select Email. By hitting the [Set properties]-button you can define the properties of this step. For more information on how to create an email, please read this blog article here.
Step 2: Create MSCRM-ADDONS.com AutoMergeWorkingIntems
Next, we want to create a new MSCRM-ADDONS.com AutoMergeWorkingItem, which makes sure that the SharePoint document will be uploaded to the email properly. To do so, please add a new step. Again, click on the [Add Step]-button and select Create Record. Then, type in a step description and use the drop-down menu below to set the Create:-section to MSCRM-ADDONS.com AutoMergeWorkingItems. Next, click on the [Set Properties]-button.
The properties for this step could look like in the example above, which are explained below.
Type in the name of your newly created step - a name that reminds you of what it contains.
Open the drop-down menu and select AttachToEntity. Select this option to attach a created document to any Microsoft Dynamics 365 standard and/or custom entity.
Insert the PrimaryRecordUrl here by using the Form Assistant on the right side (highlighted in yellow). A description of how to set a PrymaryRecordsUrl-field can be found in this blog article.
❹ EntityToAttach (Record URL(Dynamic))
Set the cursor in this field and select Create Email (Email) in the Form Assistant on the right side.
❺ SharePoint URL
Insert here your SharePoint URL, which can be dynamic or static.
After defining the properties please save your newly created process and do not forget to activate it in the My Processes-section by hitting the [Activate]-button in the command bar.
That’s it! We appreciate your feedback! Please share your thoughts by sending an email to email@example.com.