You may have images to show on Header, Title, T&C or Footer sections or you may show the product images on line item level. Below is the explanation of how to work with images for both the scenarios –
Images to be shown on Header, Title, T&C or Footer sections –
You can upload the images from your location PC using WYSWYG editor Image option and can change image attributes like image size by right clicking the images after it’s uploaded and selecting Image option like shown below –
Images to be shown for Product Line Items –
In many cases you may have images for individual Products which you want to show in the PDF Tables. To make it easier to show the images on Tables, you can create 2 custom fields – Image URL (On Product Object) and Image Formula field on Objects like Quote Line Item, Opportunity Product etc.
Recommended practice is to store the individual images under Static Resources and specify the image URL into Image URL field on Product level.
Image Formula will look like following –
IF(
PricebookEntry.Product2.sfcloud__Image_URL__c ==”,
‘Image Unavailable’,
IMAGE( PricebookEntry.Product2.sfcloud__Image_URL__c , “Image Unavailable”, 75, 75)
)
You can use this Image formula field as PDF Column which will render the images into PDF –
You can also change height/width in this formula field.
For Images stored outside of Salesforce –
In some case images are stored in external repositories and in order to avoid duplication you may want to use external image. In those scenarios, one additional step needed is to add domain where image is stored as Remote Site Settings –
– Go to Setup menu >> Administer >> Security Controls >> Remote Site Settings >> New
– Enter remote site name, URL (For example, http://MyURL.com), mark it Active and click Save
Note : If you are using Product Bundle app as well, Image URL and Formula fields described above are provided as part of the Product Bundle app package.