Attach SharePoint files to Outlook email using Shared Email Templates

This blog post was made to describe in an easy and detailed way how attach SharePoint files to your Outlook email using a macro in Shared Email Templates and apply it within your team templates as you go forward.

About Shared Email Templates in brief

My guess is that I am not the only one who deals with Outlook emails, templates and attachments almost every day. Sometimes the process is quite weary and taking up much time. If you don’t have a personal assistant or prefer to keep in check everything yourself then stay with me and get acquainted with our Shared Email Templates add-in. The app may help you to insert and save files in a few clicks, manage them and send at any minute in future.

Here is what I do to escape the boring reattachment flow within my team: I create a SharePoint site, add files there and make up templates using the special attachment macro. As a result, I have a ready-to-use pattern available for pasting with a single click of a mouse:
Attaching a file to Outlook email with a macro

Would you like to have the same time-saving feature in your Outlook? If so, please be my guests today and follow the steps I describe in this post.

SharePoint - creating your own team

SharePoint - the name of this cloud-based service says it all. Created by Microsoft, it helps their users to access, share and manage information safely. Have you already tried it out? It reminds me of OneDrive in places, yet the structure is different, and it provides you with extended communication opportunities. Let us explore how Shared Email Templates for Outlook work with this platform and what exactly we need to do.

For a brief start, sign in to in your browser and tap the launcher icon in the top left corner, then navigate to SharePoint to open the app:
How to open SharePoint

Team site would be a perfect place to store your content and keep it available for the users you specify. Also, it is so easy and quick to arrange it here:

  1. Click on Create site in the Ribbon and choose Team option:
    How to create a team site in SharePoint

    In a general way, you simply create a group where you as an owner can add other owners/members, collect files and use them into Shared Email Templates onwards.

  2. Ready? Now enter your Team site and click on its name, then move to the Members tab. This is a section to review existing members or navigate further to add them:
    How to find the Members tab

Tip. As you might notice there are two small icons in the top right corner under the account bar. Use them as a quick step to add more members into the team or enable the Following option.

Chose Follow or add members

Upload and share at the same time

When adding an attachment to your shared template, please keep in mind that this file must be available for your teammates as well. It is a kind of a crucial rule, that’s why I suggest creating a separate Document library or several for better convenience and variability:

  1. By default, you are in the Home page of your Team site, proceed to New and select the corresponding item:
    How to create a new document library
  2. Give it a name, tick Show in site navigation and wait a while unless it appears on the right in your menu.
  3. Now open this library, create a folder and fill it up with the desired items by clicking the Upload button:
    How to upload a file into the folder

    Tip. Alternatively, drag and drop the files from any location to your SharePoint window.

This method can be considered as the most practical one. Once documents are placed in a Document library, all the Team site members get access to them automatically. No additional sharing settings are required.

Yet, it is possible to share a template attachment personally, if necessary. Right-click on your item and choose Manage access:
Managing access of a file

Then add user(s) through the Direct access option:
Granting direct access to a user

I know the description above might sound a bit complicated, but one time would be enough to understand the whole thing ;)

What exactly the ~%ATTACH_FROM_SHAREPOINT[] macro does

This particular macro builds a bridge between a template and an attachment you keep there. So, open Outlook > Shared Email Templates > New template and select the ~%ATTACH_FROM_SHAREPOINT[] macro from the Insert macro drop-down list:
Choose the corresponding macro

You will get a Microsoft authorization request at once, please don’t skip it so you might reach your SharePoint sites and folders. Then navigate through sites to your Team site > Document library > Folder. To select the item, just double-click on it:
Navigate to the necessary file

Now give your template a nice name and hit Save.

Tip. If you reached the intended Document library but don’t see the necessary file in the list, please make sure to create a folder first and place the file there.

The result will be pasted directly in square brackets [] inside your macro. Let us have a look at the strange link we got:
An email template with an inserted macro to attach a file

If you do not mind, I will explain a bit why we need this abracadabra. This is a personal record of an attachment’s path built by our Outlook add-in. Any changes made manually would corrupt it. Copy/pasting a link from your browser inside the brackets will not work either.

Now add text or image to complete your template, as you please. Hit the Save button to store it and that’s all! It will be there for you when you need to send it and won’t request to attach the same file at every turn.

Keep in mind a few warnings

The add-in will allow you to save a template with an attachment when you are the one who created it, for instance. Yet, the reminder below appears when you forget to share this particular file or folder with others:
Warning that the file is not shared

It will also fire an error for a team member who will attempt to use such a template without access permissions:
An error that the file can’t be pasted as it is not found

That was my experience, and I am glad to pass it on to you. BTW, you can always reach out to me in the comment section below. See you again soon!

Table of contents

Post a comment

Thank you for your comment!
When posting a question, please be very clear and concise. This will help us provide a quick and relevant solution to
your query. We cannot guarantee that we will answer every question, but we'll do our best :)