This tutorial focuses on how to automatically fill the Cc field, insert the recipient's name into the message body, as well as add images, attachments, and dates.
With macros, you can easily avoid repetitive actions. You can automatically attach files, insert pictures, or fill in the To, Cc, Bcc, and Subject fields. You can also create fillable fields that are replaced with the necessary values either automatically or via dialogs that show up when you insert a template into an email.
Note. A maximum of one nested level of macros is supported: ~%Macro1{~%Macro2{}}
To download a quick Macros cheat sheet, click the button below.
This tutorial focuses on how to automatically fill the Cc field, insert the recipient's name into the message body, as well as add images, attachments, and dates.
This video explains how to create fields for entering a text value, selecting from a dropdown, picking a date or time, and selecting a value from a dataset.
Tip. To quickly find a macro, use the search box.
An inserted macro is shown in the text of a template with a macro placeholder.
You can choose between two macros styles: Default and Dashed. With the Dashed macros style, you can see formatting that is applied to macro placeholders in your templates.
Default macros style | Dashed macros style |
---|---|
You can change the Default macros style to the Dashed one by going to Profile > My Account > Edit my account.
With Shared Email Templates macros you can:
Tip. If you see the HTML icon above a text-entry box in a macro dialog, it means that you can enter a piece of HTML code.
To create interactive fillable fields that will be replaced with values you enter or select via dialogs when inserting templates into email messages, use the WhatToEnter macro. For detailed information, visit this help page: Add interactive fillable fields.
To put some email addresses or text into email fields, you can use the Fill and Add macros.
Note. It doesn't matter where in the text of a template you insert the Fill and Add macros. They don't show up in the message body.
By default, the text added by the Add macro is inserted after the text that the Subject field already contains. If you want to add the text to the beginning of the Subject, select the Before checkbox when inserting the Add macro.
Attach files from OneDrive, SharePoint, or URLs with the Attach macro. Or use the WhatToAttach macro to create a reminder. Here is the detailed guide: How to attach files to your templates
To insert images from OneDrive, SharePoint, or URLs, use the InsertPicture macro. For more information, visit the How to insert pictures into your templates page.
Create auto-fillable fields to automatically insert information into the message body.
If you want to insert the Subject line content into the message body, use the Insert macro. This macro can also help you add the current date and current time to your email message.
Use the Insert macro to insert the content of the To, Cc, or Bcc field into the message body.
You can insert the first, full, or last name of the recipient or the sender into the message body with the Insert macro.
Note. If the name of the recipient isn't displayed in the To field, the macro will insert the recipient's email address instead.
To easily add mailbox, profile, and team properties to your templates, use the Insert macro. Here is the How to use team, profile, mailbox properties guide.
Use the Insert macro to insert a value from a dataset into the message body. Learn more.
To leave an internal note in a template for yourself or your teammates, use the Note macro. It will be present only in the template itself and won't change an email message.
In the template preview, the macro placeholder looks like this:
To see the text of a note, simply hover the cursor over the macro placeholder. To open the note, click the macro placeholder.
If you want notes to open automatically, choose one of the two following ways:
As a result, such a note will open automatically.
As a result, all the notes you have in your templates will open automatically for your profile or for your team(s).
The Clear macro will help you clear the message body as well as the To, Cc, Bcc, and Subject fields.
With the DisableIf macro, a template won't be inserted if the condition that you specified is met.
You can create appointments and schedule meetings with the help of templates and use, for example the Fill, Add, and Insert macros in them. Detailed information is available on the Templates for appointments and meetings page.
Note. You can use nested macros as long as they don't exceed one nested level.
If you want to combine two macros making them work together for you, just nest one of them within the other. Suppose you would like not only to automatically fill in the Subject line with some text but also to have the opportunity to change this text if necessary. In this case, you'll need to nest the WhatToEnter macro in the Fill macro.
When inserting such a template into your email message, you'll see a dialog showing your default text for the Subject line. You can always change that text if you want to.
Responses
Hi, is there I can enter some of my ~%WhatToEnter into the Subject? For example, some of my fillable fields include the date of an event and the event name. I would like those to automatically appear in the subject as well.
Hello Lawson,
Thank you for your question. Please try the macro below:
~%AddSubject[~%WhatToEnter[{title:"Event Name"}]: ~%WhatToEnter[{date,title:"Event Date"}]]
BTW, if you copy/paste it, please don't forget to clear macros formatting before hitting Save. Thank you.
Can I format a date? or even display just a part like DATE(MONTH) ?
Hello Cristian,
Thank you for your questions.
If I understand your request correctly, please try to use the ~%WhatToEnter macro that allows you to pick a date in the calendar when inserting a template into a message. You can also set a certain format and language for your dates. For more details, please see this guide:
https://www.ablebits.com/docs/outlook-shared-templates-macros-whattoenter/#date
If it is not exactly what you need, then please clarify your request.
I have unique links that I send a lot, I would l like the hyperlink to be "click me" style but is there a quick way to get that added in when i start the snippit via what to enter?
Hello Vignas,
Thank you for your question.
If you'd like to quickly insert a unique hyperlink into an email depending on the context of your message, I'd recommend using the ~% WHAT_TO_ENTER[] macro in the combination with Dataset. I have just sent you the detailed instructions by email.
In case you have any questions or need further explanation, please do not hesitate to email back.
Hi,
I just cannot get the results from the ~%WHAT_TO_ENTER[] macro you posted above here.
The syntax of Pick Date ist unclear as well as I do not get the result even when trying to copy your examples here.I still get the Question Box (which does look different then yours given here) and everything is an item from the dropdown list, that's it.
Can you please provide the full syntax and potential options ?
Hello Lars,
Thank you for your comment. Sorry to hear that the instructions above are not clear for you.
If you'd like to insert a date into a certain place in your message using the ~%WHAT_TO_ENTER[] macro, please do the following:
- Click the New button at the bottom of the add-in pane to create a new template.
- Type in the template text and put the cursor where you'd like to insert a date. Then open the Insert Macro drop-down and choose ~%WHAT_TO_ENTER[] from the list.
- You will see the What To Enter dialog window with three fields. Click on the down arrow in the top field and select "Date".
- Enter the title for the window that will appear when inserting the template, for example, "Due date".
- Then click Insert, the macro will look as follows: ~%WHAT_TO_ENTER[{date,title:"Due date"}].
- Save the template and try to insert it into the email. When you do this, you will see the dialog box called "Due date" with the current date. You can click on the down arrow in the date field to open the calendar and pick another date.
If your case is different, then please explain in detail what you'd like to do and we'll help you with creating a necessary macro. Feel free to email us at support@ablebits.com for further assistance.
Hello, is it possible to get multi-line text as WHAT_TO_ENTER value?
Hello Giuseppe,
Thank you for your question. I have just replied to your query by email. Please check your Inbox.
Hello Katerina, i have the same question as Giuseppe. Thank you.
Hello Luca,
Thank you for your question. Yes, it is possible to enter multiple items in the ~%WHAT_TO_ENTER macro choosing the Dropdown list option. Please find the detailed manual here: https://www.ablebits.com/docs/outlook-shared-templates-macros/#what-to-enter
I'm trying to use the WHAT_TO_ENTER to have it in a drop-down list, however it always appears to me like the last example, an empty box to type the information. Is there anything i can do to have it in a list?
Hello Kelvin,
If you want to have a drop-down list to be displayed when inserting the ~%WHAT_TO_ENTER[] macro, you should enter list items through a semicolon in the square brackets next to the macro name like in the example above, ~%WHAT_TO_ENTER[Item 1; Item 2; Item 3].
If you mean something different, then please send us the HTML code of your template for checking. Simply select the template you're having difficulties with and hit Edit. Then, find and click the > icon to open the View HTML pane. Select all the text you see in the HTML window, copy it, paste in a Word document and send it to support@ablebits.com. We'll try to help.
There are times where I want to use ~%WHAT_TO_ENTER[] to get some information and then use it again later, but I don't want to have to ask again. Can you consider adding the ability to store and access variables? Something like ~%SAVE_TO_VARIABLE[1, Prompt Message] and ~%USE_VARIABLE[1]. You could use indexes to reference which variable to save and use and limit a template to say 10, 20, or whatever number makes sense.
Thanks
Hello Michael,
I have just replied to your query by email. Please provide us with the information requested in the email so that we'll be able to help you better. Thank you.
Hello
Same question.
Typically I want to use a ~%WHAT_TO_ENTER[] entry into body message AND into Subject field without typing twice.
Thanks
Hello Patrick,
Good idea! I have just added it to our backlog. I will discuss with developers and definitely include it to the next build. Thank you.
Patrick,
Please ignore my previous comment.
You can use a WHAT_TO_ENTER macro with the same "window title". In this case, you will be prompted once. Plus, you can nest the WHAT_TO_ENTER macro into any *SUBJECT macro. Thank you.
Post a comment
Seen by everyone, do not publish license keys and sensitive personal info!