Let see how we can populate Signature from CRM to Word Document using Cloud flows
First we need to understand how to create word template with Content Controls –
Step 1 : Create Word Template with Content Controls
In Word Document, Select Developer Tab.
Under the Developer Tab, Insert picture control.
After Inserting a picture control, Click on Properties -> Name the Title and Tag according to your requirement.
In my case I have named title and Tag as Signature.
Now we have created a Word Document with content controls.
Upload this document in your SharePoint
Step 2: Populate Signature Field using Cloud flows
- Signature field in CRM is pen control and it is a text field which contains base 64 separated by comma
- Split the above field by “,” to get the text separated by comma
Use below expression –
split(triggerOutputs()?[‘body/cf_signature’],’,’)
Output of above expression –
- Initialize a variable of type Object and set the Object as shown below-
Content is output of split action, To get the output of split action use below expression –
outputs(‘Compose_2’)[1]
Syntax – outputs(<stepname>)[position of array]
And save the object in a Compose
- Populate a Microsoft Word Template
Add action “Populate a Microsoft word template” in flow
- Create File in SharePoint
File Content of Create file step is the output of Populated Word Template
Input –
Output –
Hope this helps!