The Encodian population engine supports image insertion using the following two methods:
Please ensure you have followed the Spreadsheet Preparation steps.
Spreadsheet Preparation
When using the image token you must add the token inside a text box, please follow this instruction:
Insert Image - Hyperlink
The URL must be publicly accessible, if the URL requires authentication the image cannot be accessed and therefore would not be inserted.
Example Spreadsheet: Encodian - Template Syntax - Image Url.xlsx
Example JSON Data:
{
"imageUrl": "https://cdn.apps-encodian.com/logos/Encodian_Logo.png"
}
The image token requires a single parameter, the URL value, see below:
<<image [imageUrl]>>
This generates the following output:
Clearly, this doesn't look great! Firstly to remove the grey border from around the image:
Secondly, utilise the switch, this is further explained in the Image Formatting section of this article.
<<image [imageUrl] -fitSize>>
This generates the following output:
Insert Image - Base64
Example Spreadsheet: Encodian - Template Syntax - Image Base64.xlsx
Example JSON Data:
{
"imageBase64": "iVBORw0KGgoAAAANSUhEUgAAAMEAAAA8CAYAAADfTt5bAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAB3RJTUUH5QkcDA8uz9ZCowAAAAd0RVh0QXV0aG9yAKmuzEgAAAAMdEVYdERlc2NyaXB0aW9uABMJISMAAAAKdEVYdENvcHlyaWdodACsD8w6AAAADnRFWHRDcmVhdGlvbiB0aW1lADX3DwkAAAAJdEVYdFNvZnR3YXJlAF1w/zoAAAALdEVYdERpc2NsYWltZXIAt8C0jwAAAAh0RVh0V2FybmluZwDAG+aHAAAAB3RFWHRTb3VyY2UA9f+D6wAAAAh0RVh0Q29tbWVudAD2zJa/AAAABnRFWHRUaXRsZQCo7tInAAAWdklEQVR4nO2ce5hfVXnvv993rf27TWYmA4GEhMwlCSBgwIRMJgkSgkBuBK1UW+051qJiFS0q5zwiTxuOipc+ltJytB5Fa1tO0VqQlgPkJvSBIJAbAUQJxjCZJM39nrn+fnuv9z1//GbCBGaSyTAJbWd/nmf/kcxa73732uu71rvWu/aPZoaUlOGMvN0OpKS83aQiSBn2pCJIGfakIkgZ9qQiSBn2pCJIGfakIkgZ9qQiSBn2pCJIGfakIkgZ9qQiSBn2pCJ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ToL2oqxGbTsyeDgoSxymQhehvLKwEsGkWTBsuvrB+Lb+k1Lm1kM71dNvmawzUKXCHs++hEIPQSuZGYbYgu3spj/2EvbntgBACTNU44Q0g5Ih4jv84N/tUDCdQLsJNhOsMPwejyxqvmRPR2dyUeC2m0w2yjiEuei8rkdOjjnQchhs/CvIdj7Vm9e8n972zd7SFc3P3qHwT6sGlYKfVv5vI8/evZHxCVm2KQIi2Mr/W7vA3y92yIE3BAs/G+Ae7z48vkjuh5fOg18WAw3irhm0nUA7KBIp1qgJ42UjvIzokPg2oDXc1RrNi//YQj2+2b2pNB1eMnAsce+A4jtQvkcIX/lJOogpR1gJ4kAAEIpAewgpJ1gBxz7TIhSqAB6ynVSXFdyRjyonaQhC4f8xc8tx45ZHzmy1c2/9+8zsvdQolUjhsY2zagqIcAUAGGMPNyvomxmwCcHV21ffhDA4in11/1ALLncKS4w0RoaghF7nMlGceHpNc0r9vauF3fGL7osP5SYiECFzkoV2eqWN9qvqZPW0lZ8KXHJmWYWNMTOw17pXaY7tPnWzPOv+8dQsitBvUhNq0EWncpWp3h+1bbcKjvOd9Orm5c+OGPcjEdDdtTlRHwpjOPM4A04QPBVH+Tp57Ydfy2zdsuS3QA+N3PCNT8I6i8HMFFpBW9un1hYe7BQtWLDhgfi6fXXHVCLK8w5uthaa+qltXMLn0YIv6tQFYFIIm1RaD2mzdZseWz55Mlzn65oxewEbioRxgioZrKJEZ5YvWnphstrrz2n6PiqqQVIyUeiGwEgMPwpYKMMSBSxV2if30f4EH6WGF4xWFDEzgfZn6tt7zjec/fHKfsFupSU/yykP8ibMuxJRZAy7ElFkDLsSUWQMuxJRZAy7ElFkDLsSUWQMuxJRZAy7ElFkDLsSUWQMuxJRZAy7Pn/veLm6x0x+vwAAAAASUVORK5CYII="
}
The image token requires a single parameter, the Base64 value, see below:
<<image [imageBase64]>>
This generates the following output:
learly, this doesn't look great! Firstly to remove the grey border from around the image:
Secondly, utilise the switch, this is further explained in the Image Formatting section of this article.
<<image [imageBase64] -fitSize>>
This generates the following output:
Image Formatting
The image token requires a single parameter, the URL value, see below:
<<image [imageUrl]>>
Additionally, the following switches can be added to control how the image is formatted once inserted into the text box within the spreadsheet:
The -keepRatio preserves the size of the textbox and stretches the image within bounds of the textbox preserving the ratio of the image.
<<image [imageUrl] -keepRatio>>
The -fitHeight preserves the width of the textbox but changes its height according to the ratio of the image.
<<image [imageUrl] -fitHeight>>
The -fitWidth preserves the height of the textbox but changes its width according to the ratio of the image.
<<image [imageUrl] -fitWidth>>
The -fitSize changes the size of the textbox according to the size of the image.
<<image [imageUrl] -fitSize>>
The -fitSizeLim changes the size of the textbox according to the size of the image without increasing the size of the textbox.
<<image [imageUrl] -fitSizeLim>>
0 Comments