Advanced mode allows you to define custom expressions for fields and spans, giving you greater control over the markup in your template.
To access Advanced mode, click an existing markup or insert a new one, and then select the
Advanced mode
switch in the top right corner of the work pane.
It also provides predictive text suggestions based on your input, helping improve accuracy, formatting, and usability. Suggestions are displayed in a structured and sorted order, where variables appear first, followed by functions, making it easier to locate the right option quickly.
When browsing suggestions, authors can see the variable type, such as Decimal number, directly within the suggestion list. Additional variable details are also displayed, including the associated question and the data type, giving users more context without leaving the editor.
It also provides users with a
See documentation
link, allowing quick access to the relevant help article for any function or operator directly from where you are working, without needing to search for it separately.
Clicking the link opens the relevant help article in a
new browser tab
, so the current work is not interrupted.
When you select a function in Advanced mode, the editor automatically fills in the function with placeholder names showing you exactly what information you need to provide. For example, when the
workday
function is selected, it appears as
workday(date, days)
, where
date
and
days
are highlighted to indicate the values you need to fill in.
At the top of the editor, a helpful description panel appears explaining what the selected function does. In this case, it tells the users that the function constructs a date value using a year, month, and day, and warns that the function will not work if the values do not make up a valid date.
The panel also includes examples to help you better understand how to use the function correctly before you start entering your own values.
Once you have finished building your expression, you can click the
Apply
button at the bottom right to save it or click
Undo
if you want to revert your last change. This makes it much easier to use functions correctly, especially if you are not familiar with the required inputs.
You can also undo the last change from the toolbar using the undo

option and can reverse the undo command by using the redo

button.
View and Edit variable details
In Advanced mode, you can also view and edit the details of any variable directly within the expression editor. Clicking on or positioning your cursor within a variable name instantly displays that variable's details, so you can understand and modify its properties without leaving Advanced mode.
When you click on or place your cursor within a dictionary variable name in the expression, the system detects which variable is in focus, highlights it in the expression editor, and displays its details in the Variable details form below the expression editor field. The form contains the same information as found in the Questionnaire tab or Computables section, covering general and input settings. If the selected variable is external, its details will be shown but cannot be edited.
The form stays visible while the variable is focused. If you click on a different variable in the expression, the form updates automatically to show that variable's details. The form hides when you click outside any variable in the expression, or when you navigate to a different tab or screen.
Any changes made in the Variable details form are saved automatically when you select a different variable type from the dropdown, remove focus from a field, or click on a different variable in the expression.
The following examples illustrate the types of expressions you can create in Advanced mode.
Use arithmetic operators to perform calculations in fields
For example, to calculate a product price including VAT, you can use the expression ProductPrice * 1.2, where
ProductPrice
is a decimal number variable containing the net price.
Apply formatting to control how values appear in the document
For example, to insert a company name in uppercase, use CompanyName format upper, where
CompanyName
is a text or text selection variable. You can also use datatype‑specific formats to change how values are displayed. For example, to insert a rent amount in words, use RentAmount format "currencywords", where
RentAmount
is a decimal number variable. Datatype‑specific formats must be entered in double quotes. For more information, see the help section on
Formats.
Combine multiple conditions in span expressions
For example, you can use the and operator to combine conditions such as: ContractPrice is more than 1000, and Jurisdiction is "England and Wales".
When using Advanced mode, ensure that expressions follow the required syntax so they can be evaluated correctly. Refer to the help documentation for additional examples and review your template regularly to confirm that automation logic has been configured as intended.