Template

The template is a text or binary* source file that the program uses as a pattern. It contains three type of data: commands, labels, and static content:

  1. The static content will be copied to the result file without any modifications.
  2. The labels will be replaced with the content defined by the label.
  3. The Commands define interpretation rule of the content.

* for professional edition of the software product only.

Labels

There are three types of labels now:

  1. Direct pattern engine call: ^^=<pattern>^^. Please refer to Pattern Engine manual (Ctrl+F1 hot key) for details.
  2. ^^Counter^^ label will be replaced with a number of current file number starting 1.
  3. ^^File^^ or ^^File full^^ label will be replaced with a current file name or with a path in the second case.

Commands

There are two commands available now:

  1. ^^repeat N[ to M]^^ ... ^^end^^ - will repeat the block of content N times or between N and M times in the second case.
  2. ^^optional[ NN]^^ ... ^^end^^ defines the optional block of code. NN defines probability between 1 and 100%. Default probability is 50%.

All labels and commands are case sensitive. Extra spaces between label or command and optional parameter are prohibited.

Template

The user allowed entering the text of the template immediately as well as provide the external file name. The second way is only available for binary templates.

DTM File Factory: template editor window