Skip to main content
Version: Classic

Outlook (New): template creation

This page explains how to create templates in primedocs desktop for the web-enabled Outlook version Outlook (New).

tip

Not familiar with the primedocs add-in in Outlook (New) yet? Read this page: Word Templating Basics



warning

At the outset, ensure that

  • the administration view is activated in primedocs desktop. the Outlook (New) template you wish to edit is only visible to you.

Tools

When editing or creating templates for Outlook (New), we are in two areas:

  • in Outlook (New) via the application or browser: in an open empty email and in the sidebar of the primedocs add-in in the templating menu.
  • in the template editor of a primedocs template for Outlook (New). The template editors are designed so that the template is edited in HTML.
tip

Since all email messages in Outlook (New) are HTML-based, the templates in primedocs are also created in HTML in a template editor.

Outlook (New)

When creating a template, first open a new email message in Outlook (New). This is where you will build the template with Outlook.

Templating

The templating menu is required for template creation. To do this, open the primedocs add-in: primedocs Add-In - Outlook (New)

Client-OutlookNew-User-20240912-105756.png

When you click on your profile picture, you will see the Templating option. Click on it.

note

If you do not see Templating, you are not authorised to edit Outlook (New) templates. Contact your organisation's administrator.

Client-OutlookNew-Templating-20240912-110814.png

The templating menu will then open.

note

IMPORTANT
The templating menu is an integral part of creating Outlook (New) templates.

It simplifies the implementation of templates with HTML by offering conversion options from the visible content in the email message to HTML and vice versa.

Click on ‘Insert message as HTML into text area’ if you want to convert the content in the email message to HTML.

Click on ‘Insert HTML from text area into message’ if there is HTML in the text field and you want to insert it into the email message for editing or testing purposes.

We will look at this in detail below.

Template Editor(HTML)

The second tool is the HTML Template Editor. It is opened by clicking on Editor in the Template Editor of a template for Outlook (New).

In all HTML Template Editors, first select the document language from the Language drop-down list.


Template creation

To create templates, you now work with both tools in parallel: the primedocs add-in and the HTML template editor.

Procedure

Basically, proceed as follows:

  1. Create a template for Outlook (New) and configure the template status to In progress
  2. In the open template editor, click on Editor to edit the template. A new window will open: Template Editor, the HTML template editor.
  3. In Outlook (New), prepare the desired content, email or signature in the email message.
  4. Generate the HTML for the text in the email message using the primedocs add-in.
  5. Insert the HTML into the HTML Content field in the HTML template editor.
  6. Create the forms and fields required for the template and add them to the HTML Content field: Forms and fields can be called up in the HTML using the syntax {{Name}}.
  7. Convert the HTML to plain text in the HTML template editor using ‘Extract text from HTML’.
  8. Save and close the template editor.
  9. Synchronise.
  10. Test the template using the primedocs add-in in Outlook (New) and repeat steps 2-9 if necessary.
  11. Release template and authorise users.

Templating menu (steps 3 and 4)

Example of using the templating menu

Client-OutlookNew-Templating-CreateHTML-20240912-123733.png

The text for an email template was created.

Then, the HTML for the content was generated using the ‘Insert message as HTML into text area’ button.


Creating an email template

The email template is very easy to create. Therefore, we will start with this Outlook template.

Preparation

  1. Open the tools mentioned above to get started.
  2. For the template editor: Click on New Template in primedocs desktop and select Email.
  3. In the template editor that opens, click Editor to edit the template. A new window will open: Template Editor, the HTML template editor.
  4. In the HTML template editor, first select the document language from the Language drop-down list.
warning

If the template is available in multiple document languages, do not forget to activate all desired document languages in the template editor.

  1. The subject line for the email template can be set in the Subject field.
  2. Email addresses can be entered in the To, Cc and Bcc fields, separated by semicolons ( ; ).
  3. Switch to Outlook (New) and create the desired text. Use the Templating menu to generate the HTML for the text: Word Templating Basics
  4. Copy the generated HTML from the templating menu.
  5. Switch to the HTML template editor and paste the HTML into the HTML content text field.
  6. Click on the </> button to structure the HTML more attractively. In our example, the HTML looks like this:
<div class="elementToProof" style="font-family: &quot;Segoe UI&quot;, &quot;Segoe UI Web (West European)&quot;, &quot;Helvetica Neue&quot;, sans-serif; font-size: 10pt; color: rgb(0, 0, 0);">Lieber [Name]</div>
<div class="elementToProof" style="font-family: &quot;Segoe UI&quot;, &quot;Segoe UI Web (West European)&quot;, &quot;Helvetica Neue&quot;, sans-serif; font-size: 10pt; color: rgb(0, 0, 0);">
<br />
</div>
<div class="elementToProof" style="font-family: &quot;Segoe UI&quot;, &quot;Segoe UI Web (West European)&quot;, &quot;Helvetica Neue&quot;, sans-serif; font-size: 10pt; color: rgb(0, 0, 0);">Herzlich Willkommen im Team!</div>
<div class="elementToProof" style="font-family: &quot;Segoe UI&quot;, &quot;Segoe UI Web (West European)&quot;, &quot;Helvetica Neue&quot;, sans-serif; font-size: 10pt; color: rgb(0, 0, 0);">
<br />
</div>
<div class="elementToProof" style="font-family: &quot;Segoe UI&quot;, &quot;Segoe UI Web (West European)&quot;, &quot;Helvetica Neue&quot;, sans-serif; font-size: 10pt; color: rgb(0, 0, 0);">Wir wünschen Dir viel Spass.</div>
<div class="elementToProof" style="font-family: &quot;Segoe UI&quot;, &quot;Segoe UI Web (West European)&quot;, &quot;Helvetica Neue&quot;, sans-serif; font-size: 10pt; color: rgb(0, 0, 0);">
<br />
</div>
<div class="elementToProof" style="font-family: &quot;Segoe UI&quot;, &quot;Segoe UI Web (West European)&quot;, &quot;Helvetica Neue&quot;, sans-serif; font-size: 10pt; color: rgb(0, 0, 0);">Alles Gute!</div>
<div class="elementToProof" style="font-family: &quot;Segoe UI&quot;, &quot;Segoe UI Web (West European)&quot;, &quot;Helvetica Neue&quot;, sans-serif; font-size: 10pt; color: rgb(0, 0, 0);">
<br />
</div>
<div class="elementToProof" style="font-family: &quot;Segoe UI&quot;, &quot;Segoe UI Web (West European)&quot;, &quot;Helvetica Neue&quot;, sans-serif; font-size: 10pt; color: rgb(0, 0, 0);">
<br />
</div>
  1. It is worth tidying up the HTML afterwards. If you do not have the necessary HTML knowledge, please contact primedocs Support.
  2. This is what the revised HTML looks like:

Text

Dear [Name],

Welcome to the team!

We hope you enjoy yourself.

All the best!

HTML-Code

<div class="elementToProof" style="font-family: &quot;Segoe UI&quot;, &quot;Segoe UI Web (West European)&quot;, &quot;Helvetica Neue&quot;, sans-serif; font-size: 10pt; color: rgb(0, 0, 0);">
Dear [Name]<br>
&nbsp;<br>
Welcome to the team!<br>
&nbsp;<br>
We hope you enjoy yourself.<br>
&nbsp;<br>
All the best!
</div>
  1. For this email template,
  2. the phrase ‘Welcome to the team!’ should now be controlled via a Forms selection and thus made dynamic,
  3. and the subject selected in Forms should appear in the subject field of the email.

Forms (preview)

Forms-20240912-130859.png

Forms-Code

The configuration contains a choice field, which is displayed as a drop-down list in Forms.

<FormsConfiguration>
<Elements>
<Choice Id="Subject" translate-Label="Texts.Subject" Required="true" translate-ValidationMessage="Forms.Info.CompleteField">
<Option Value="Herzlich Willkommen im Team!" Label="Herzlich Willkommen im Team!" />
<Option Value="Herzlichen Glückwunsch zum Geburtstag!" Label="Herzlichen Glückwunsch zum Geburtstag!" />
<Option Value="Viel Erfolg!" Label="Viel Erfolg!" />
</Choice>
</Elements>
</FormsConfiguration>

Text field with sentence

<FieldsConfiguration>
<Fields>
<Text Name="Content">
<Code>
function main(){
// Variable containing the first part of the sentence.
let sentence = "We wish you ";
// For each selection in the Choice field, something different is output.
switch($("Forms.Subject")){
case 'Welcome to the team!':
// The first part is appended to the second part.
sentence += "Enjoy getting to grips with it.";
break; // Exit switch() when a case has occurred.
case 'Happy birthday!':
sentence += "All the best on your birthday";
break;
case 'Good luck!':
sentence += "Good luck with your exam.";
break;
default:
// This will not happen because the choice in forms
// is marked as ‘required’.
sentence += "[Select]";
}
// The variable containing the complete sentence is returned.
return sentence;
}
</Code>
</Text>
</Fields>
</FieldsConfiguration>
  1. Forms fields and fields can be called up using the syntax {{Name}} in HTML. We therefore adjust the HTML as follows:

Text

Dear [Name]

Content field content

We hope you enjoy yourself.

All the best!

HTML

<div class="elementToProof" style="font-family: &quot;Segoe UI&quot;, &quot;Segoe UI Web (West European)&quot;, &quot;Helvetica Neue&quot;, sans-serif; font-size: 10pt; color: rgb(0, 0, 0);">
Dear [Name]<br>
&nbsp;<br>
{{Content}}<br>
&nbsp;<br>
We hope you enjoy yourself.<br>
&nbsp;<br>
All the best!
</div>
  1. We set the subject accordingly with {{Forms.Subject}}.
  2. The plain text is created using the Extract text from HTML button.
  3. The template is saved.
  4. Now it is time to test the email template and check whether it looks as intended.
  5. Finally, the template just needs to be approved for the correct users: Word Dive Into Fields

Client-OutlookNew-Templating-EditTemplate-20240912-161744.png


Create signature template

  1. Open the tools mentioned above to get started.
  2. For the template editor: In primedocs desktop, click on New Template and select Signature.
  3. In the template editor that opens, click on Editor to edit the template. A new window will open: Template Editor, the HTML template editor.
  4. In the HTML template editor, first select the document language from the Language drop-down list.
warning

If the template is available in several document languages, do not forget to activate all desired document languages in the template editor.

  1. Now proceed in exactly the same way as when creating an email message (from step 5 onwards).
    The biggest difference is in the content of the text, which is usually somewhat more comprehensive in a signature than in an email template.

Example

HTML code and result

Below is an example of a signature with HTML code and how it appears in the email message:

HTML-Code

<div style="font-family: &quot;Segoe UI&quot;, &quot;Segoe UI Web (West European)&quot;, &quot;Helvetica Neue&quot;, sans-serif; font-size: 10pt; color: rgb(0, 0, 0);" class="elementToProof">
&nbsp;<br/>
Freundliche Grüsse<br/>
{{Profile.User.FirstName}}&nbsp;{{Profile.User.LastName}}<br/>
&nbsp;<br/>
<span style="font-size: 9pt; text-decoration:none">
_________________________<br/>
<b>{{Profile.User.FirstName}}&nbsp;{{Profile.User.LastName}}</b><br/>
{{Profile.User.Function}}<br/>
{{Profile.User.Phone}}&nbsp;(Direkt)<br/>
<a href="mailto:{{Profile.User.Email}}" style="color: black; text-decoration:none">{{Profile.User.Email}}</a><br/>
&nbsp;<br/>
<a href="https://{{Profile.Org.Web}}" style="color: black; text-decoration:none">
<img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAKcAAAAyCAYAAAA5vcscAAAABHNCSVQICAgIfAhkiAAADgVJREFUeJztnH90VdWVxz/73PveS0gkEAJYRAZMyHuC44hdaLU6bW2XFWec1nE52PmhHVtF5CVKp/zIA+udpeSBKGgStLSD2nZ1bG07djrq6PijtqD4E6oj+F4SEEVBgVjlZ/LevXfPHy+JLyE/JbSzmvtZK2vl7rPPPt9zs+89955zboRBUpGsm2EjV6vKl0SYpMrbiD7t+bKueUl8M6CDjRkQ0BMyYE/HMbHI2CtB7+vNxYdrGjf95j5+9jNvSNQFDGvMQB1jkdLZfSVme7DvR8/83FXHLisgYIB3zvErVxaNcgsbBSb066z6QTZjn7rNmbvnmNUFDGsGdOcclS244qjEVH1A4RuoPtDF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A9OYcydiy5ejKE3uw0qC5IJapuH8o2/lTp/bv1YYSoeUHxb1eR9FDH9tu8gyYSul/hfVX/kcZE9YahbiMgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBgIPwftp6jEHfIXvEAAAAASUVORK5CYII=" alt="AnyCompanyLogo" width="167" height="50" style="width: 167px; height: 50px; min-width: auto; min-height: auto; margin: 0px; vertical-align: top;"/>
</a><br/>
&nbsp;<br/>
{{Profile.Org.Title}}&nbsp;<br/>
{{Profile.Org.Postal.Street}}&nbsp;<br/>
{{Profile.Org.Postal.Zip}}&nbsp;{{Profile.Org.Postal.City}}<br/>
{{Profile.Org.Phone}}&nbsp;(Hauptnummer)<br/>
<a href="https://{{Profile.Org.Web}}" style="color: black; text-decoration:none">{{Profile.Org.Web}}</a><br/>
&nbsp;<br/>
</span>
</div>

Result

image-20240912-151131.png

Explanation of HTML elements

Now we will explain the individual elements:

Elementpurpose
<div></div>A structural element that contains text or other content.
&nbsp;<br/>HTML does not recognise unprotected spaces. Therefore, it requires a protected space &nbsp; followed by a line break <br/> for an empty line.
<span style="">If the formatting of a paragraph changes (as here from 10 pt to 9 pt), it makes sense to configure this with the span tag.

The formatting is specified with the style attribute.
<a href="" style="" />The a-tag opens a link. In this case, it is an email link.

The href attribute is the actual link stored. The display text is defined between the start and end tags.

Since links are often formatted differently, the different formatting is defined with the style attribute.
<img src="" />The img tag allows you to display an image from a Base64 string.

As shown in lines 13-15, a link can also contain an image (img). This creates an image with a link.