A description of all the supported scripting commands follows.

General things to be aware of:

  1. An optional item is enclosed in []. An example would be [FROM], which means that the word FROM is optional.
  2. Unless otherwise stated, extra text appearing on a line after details required by the command are ignored.
  3. Lines containing unknown commands are ignored.

Note IconSee the notes at the end of this help topic for information about using literal text, variables and quotes.


Supported Custom Script Commands


Literal Text, Variables & Quotes

In several places field names and pieces of literal text can be used. The parser tries to be flexible in how it accepts the text, but there are limits. Unless otherwise explicitly stated, here are the rules where text is concerned:

Text

  • Text does not have to be enclosed in quotes. If it is not, the whole of the text up to the end of the line is assumed to be the text.
  • If text begins with a quote but has no other quotes, it is accepted after stripping off the quote.
  • If text has a quote at the end or in the middle but no beginning quote, the whole line is used as is, quotes and all.
  • If text has quotes around the first part of it but then has further text after it, the extra text after the quoted part is ignored.

If in doubt, quote it!

Variables

To use a variable, simply write the variable name (including the leading dollar sign ($) ) right into the text. The parser will substitute the actual value of the variable into the text. Even if the text is unquoted as allowed above, substitution of variables still takes place.

If you need a dollar sign in the line for real, just make sure it does not come right in front of a word that could make a variable name. If a dollar sign is found with a name that does not exist as a variable, they are both printed out as is.

If two dollar signs occur together and the second forms part of a legal variable name, the variable is substituted as normal and the first dollar sign is left on the line also (since it is not part of the variable name). A single dollar sign by itself will also be left intact.

A variable that represents a date can be formatted by using special identifiers. If you use the control panel then it will take care of all of this for you. But here are the full details about the syntax:

  • $DateVariable#SHORTDATE

This will display the $DateVariable using your computers short date format.

  • $DateVariable#LONGDATE

This will display the $DateVariable using your computers long date format.

  • $DateVariable#CUSTOMDATE[format_string]

This will display the $DateVariable using your specified format string.

Note that you can include the above syntax along with other variables and text. Thus, the following are examples of valid text or field names:

"&speech"

Will just display a " - speech mark

"&speechThis is quoted text&speech"

Will display "This is quoted text".

"This is quoted text with a $Variable embedded in it."

The value of $Variable will be put in instead

"$Speaker"

Quoted, variable only.

$Brother

Unquoted, variable only

This allows for much more flexible commands. For example:

  • LOOP FROM "Away Talks" WHERE $FieldName IS $FieldValue
  • Hello $Brother. This report was printed on $Today#LONGDATE.