This article will explore the image insertion as a content control or a shape through the Template Designer
, part of the Dynamics
module. This feature is exclusive for Word and PowerPoint and requires superadmin permissions on Templafy in order to be accessed.
For more information regarding working with the Template Designer, please visit this article.
Prerequisites for using the feature
- Dynamics Version 1.0
- VSTO Add-ins Version 5.5.0.867 or greater
- Images uploaded to the admin portal
- A data source containing the necessary images if they are to be dynamically inserted
Feature Overview
Templafy allows images to be uploaded on the admin portal as a part of the Company Data
. These images can be inserted into data sources and then linked to forms or the UserProfile
and become dynamically inserted into documents and presentations.
The currently supported file formats include:
- jpeg
- jpg
- png
- emf
- gif
Currently, the maximum allowed size for images uploaded to the company data is 2 MB.*
*Please note the existing difference between uploading images to the Company Data
and uploading images to the Image Library
as the latter is part of the Library module.
For more information regarding the image uploading in the Image Library
please visit this article.
Uploading of Images to the Company Data
In order for an admin to upload images to the Company Data
, the admin simply has to access the admin portal and then navigate to the corresponding tab in the Configuration
section.
The next step is to click on the Upload Logos
button and select the files designated for upload. New images will appear in the list below, once they are uploaded.
Insertion into a Data Source & Attachment to a Form
The uploaded images cannot be utilized by default if they are not inserted in a data source and linked to a form. Further information regarding data sources and forms can be found here and here.
To insert an image into a data source, simply select the preferred one or create a new one. Once that is done, insert the selected images in a column. An important note here is that the image must be inserted with its exact name as well as its extension!
Example: The inserted images are as follow Image.jpg and Image1.png
Once the images are in the data source, simply create a form that contains a Dropdown
field that is linked with the data source.
Attaching the Form and Configuring Bindings
The next step is to attach the form to the selected document and configure the bindings in the template itself.
Example: The form that was created earlier is now attached to the test document, where the images will be inserted.
Example: Adding an Image* type content control containing a dynamic binding. The binding syntax is as follows: {{Form.FieldName.Column}}
*In order for an image to be inserted in the content control, an Image type must be selected!'
If changes are made to an already uploaded document, please ensure to replace it with the new version, in order for the bindings to function.
Image Insertion in PowerPoint
PowerPoint does not allow for content controls to be inserted in a presentation, therefore it is not possible to create them using the Template Designer. Instead, we can attach image bindings to shapes on the master slide.
In order to create dynamic bindings, simply open PowerPoint and switch to the slide master, then select the desired layout and add any* type of shape. Once the shape is created, select it and configure the binding.
*avoid Text Box!
Example: A square shape was created, while it remains selected, an Image type of binding was attached to it.
Once uploaded, remember to attach the form the presentation!
Additional settings
The Template Designer also allows for the user to adjust the size of the inserted images, by inheriting either the native width or height, by statically defining the values, or by dynamically defining them.
Example: The inheritance options allowed
Static Binding
Example: Adding static values to bindings to define Width and Height. Please Note: The correct way of defining the decimal is with a dot(.) not a comma(,)!
Dynamic Binding
In order for dynamic bindings to be inserted, they need to be added to a data source first, for convenience it is usually the same one containing the images that are inserted. Simply create two more columns for Width and Height and add the desired values.
Example: The same data source used earlier now has two more added fields with respective values for the images.
Lastly, define the bindings in the Template Designer, using the above mentioned syntax.
Example: Adding dynamic bindings with the values that were inserted in the data source showed above.
Comments
0 comments
Article is closed for comments.