Document templates can be used over and over again, optimizing your team’s daily operations. Now, it’s easier than ever to create templates in S-Docs using the Template Editor.
Learn how to create a new template using the S-Docs Template Editor and add dynamic fields to your template.
1. Navigate to the S-Docs homepage.
If you are not on the S-Docs homepage, follow the instructions in Navigating through S-Docs for HubSpot.
- From the Available Templates card in the right sidebar, click the arrow icon next to “Manage Templates.”
- You will be taken to the S-Docs App homepage.
2. Click the Create template button.
You can either click Create new or Upload a document (S-Docs supports PDF upload, learn more PDF upload feature here). You may have several default templates ready for use out of the box from S-Docs.
In this example, we will create a new Quote template.
3. The template editor will open and display a blank canvas.
This editor is very similar to other text editors in use. For more information on how to use the text editor, click here.
4. Set up the data source.
To enter dynamic variables, you must select a data source to use any dynamic field in your template. Once you have selected a data source, you can drag and drop your fields into the Template Editor.
There are two methods to select a data source:
Select a data source through the Variables option in the left sidebar
1. Click the Variables icon in the left sidebar.
2. Click Select one.
3. Choose a data source from Company or Deal. In this example, we will choose Company.
4. Click Add data source.
5. A list of variables will automatically populate.
You now have access to the Runtime variable fields and the HubSpot.Company fields for the template. Add the fields you need to the Template Editor by dragging and dropping them into place.
Note: There are five classes of variables:
- All: represents all available fields
- T: Text-only fields
- Hashtag: Numerical fields
- Check-box: True or false fields
- Data: Date and time fields
These icons are visible next to the variable and indicate its “class.”
You can also select a data source using the “@ symbol.”
Click anywhere inside the Template Editor and type the “@ symbol.” Click Select Data source from the Variables list. The Variables menu will open in the left sidebar and you will repeat the steps above to select your data source.
You now have access to the Runtime fields, HubSpot.Deal, HubSpot.Contact, and the HubSpot.Company fields for the template. Click into each dropdown and add the fields you need to the Template Editor using the drag-and-drop function.
When you're ready, preview your template anytime by following these instructions: Using preview mode.
5. Changing the data source.
You can only use one data source at a time. You can change from one data source to another by using the filter icon located at the top of the Variables menu.
This filter is only visible once you have selected a data source for the Template Editor.
To change a data source:
1. Click the filter icon. Choose the new data source and click Apply.
2. You will be asked to confirm the data source. Click Change the data source if you are certain.
6. Merge data into your template.
Now, we will insert the fields from the Variables icon into the Template Editor.
First, place the fields inside the template to enter dynamic information into the Template Editor. There are two ways to do this:
- Using the Plus icon and the drag-and-drop function.
- Using the Variables icon and using the drag-and-drop function, or type the “@ symbol.”
To use the Plus icon and the drag-and-drop function:
1. From the left-hand side menu, click the Plus icon. This will open a dropdown list of elements that you can use to merge your data in.
2. Drag and drop the blocks you wish to insert into the template from the menu.
The variables and fields will be entered next to these texts in the next section.
To use the Variables icon and the drag-and-drop function:
1. From the left-hand side menu, click the Variables icon.
2. Choose Runtime or HubSpot.Company in the dropdown menu and select a variable to enter in the template.
3. Select a variable and drag and drop it into the Template Editor. For example, choose Date and drag and drop it next to the text box “Date:” in the Template Editor.
If you choose the incorrect variable, click it. Then click the vertical grip dots icon in the context menu on the left-hand side. Delete the variable using the Delete function. Click Delete. Then confirm by clicking Click to Delete.
To use the “@ symbol” to enter variables:
You can also enter a variable or a field by typing the “@ symbol” keyboard shortcut in the template editor if you prefer. Let's add the company name, for example.
Type the "@ symbol" where you want to add a field. The, click the variable you want to add or search for it in the search bar. For instance, we searched “@name" and selected Company.Company name.
This variable will be entered into the template where you typed the “@ symbol.”
Repeat the process until you have a template you’re ready to use. And there you go — you’ve created your first template! Next, learn how to use Preview Mode to see what your template will look like with real customer data.