2022.1

Table Of Contents
Example
The following script adds a paragraph to the results (elements that match the selector of the
script).
var div = query( '<div>' );
for ( let i = 0; i < 5; i++ ){
var p = query( '<p>' );
p.text( 'This is number ' + i );
div.append( p );
}
results.after( div );
Tip
The Dynamic Attachment script uses this function to add an attachment to an Email
section; see "Email attachments" on page569.
record
The record object gives access to the record that is currently being merged with the template.
Properties
Field Type Description
<fieldName>
Object Shortcut to access a field in the fields array. For
example, you can use record.FirstName to
access record.fields.FirstName.
Note
If a record has a field and a table of the
same name, record.<fieldName> will
return the table.
fields
Array The field values that belong to this record.
Page 1381