Merging Images from Salesforce Files
How to merge an image from Salesforce Files into Microsoft.
You can merge images from Salesforce Files in Conga Composer.
To merge an image from Salesforce Files:
- Build a custom formula field on the Salesforce Files Object to form
a URL to the Content document: (Salesforce Classic) Navigate to
- (Salesforce Lightning) Navigate to
- Create a new formula Field.
- For example, Field Image URL:
LEFT( $Api.Enterprise_Server_URL_100, FIND( ".com", $Api.Enterprise_Server_URL_100 ) + 4)& "sfc/servlet.shepherd/version/renditionDownload?rendition=THUMB720BY480&versionId=" & Id & "&operationContext=CHATTER"
- For example, Field Image URL:
- Write a Conga query to retrieve the formula field. Use the dot syntax to go from the ContentDocumentLink Object up through the ContentDocument through the LatestPublishedVersion Object to retrieve the custom formula:
SELECT ContentDocument.Latestpublishedversion.Field_Image_URL__c FROM ContentDocumentLink WHERE LinkedEntityId = '{pv0}' AND ContentDocument.FileType IN ('PNG','JPG','JPEG')
- Use the Detail Regions and the
IMAGE special merge field to merge the image into the template.
For example in Microsoft Word:
{{TableStart:FileImage}}{{IMAGE:LATESTPUBLISHEDVERSION_FIELD_IMAGE_URL:W=350}}{{TableEnd:FileImage}}