Automatic document numbering

The Numbering dialog of a template
In this Article

Automatic numbering gives each document made from a template the next number in a sequence, and can build the document's title from it. You control when the count restarts and how the title looks.


Open numbering

  1. Open the template from the content list.
  2. Click Numbering in its details pane's toolbar.

The Numbering dialog opens. You need an Admin or Manager role.


When the count restarts

Restart numbering says when numbering goes back to 1:

  • Never — one counter for all documents.
  • Every year (date created) or Every month (date created) — a counter per year or month the documents are created in.
  • Every year (document date) or Every month (document date) — by the document's date, which the person creating it picks. An invoice dated in December but created in January counts in December's sequence.
  • When a custom value changes — your own rule, written as tags in Restarts when this changes: ${DocumentDate:yyyy} is the same as Every year (document date); ${Department} keeps a counter for each department, where Department is a field of the template.

Restarts when this changes shows the chosen option's rule, and can be edited for a custom value.

Note

Changing the option when documents were already numbered this year or month shows a Next number box, filled in so that counting continues rather than starting again at 1. Set it to 1 to start over.


The document title pattern

Document title pattern builds each document's title from text and tags. Type $ to pick a tag. For example:

Invoice ${DocumentDate:yyyy}-${AutomaticNumber:D4} ${Client}

gives titles like Invoice 2026-0013 Blue Harbor Ltd. — the year of the document's date, the number padded to four digits, and the template's Client field. Next title under the box shows what the next document's title will be.

  • ${AutomaticNumber:D4} — the number, at least four digits. D3 gives three.
  • ${DocumentDate:yyyy}, ${CreatedOn:yyyy-MM} — a date in a format: the year, the year and month.
  • ${Client} — a field of the template by its name. A name the template has no field for becomes a question in the form: the dialog lists them under the pattern.

Leave the pattern empty and the person creating a document types its title instead.

Note

A pattern should include ${AutomaticNumber} and the tags the numbering restarts on, so that two documents never get the same title; the dialog warns when they are missing.

Click Save.


Counters

The counters of a template

Change counters, at the right of Next title, shows the last number used by each counter of the saved option — one for all documents, or one per year, month, department. To skip ahead or start again, type a new Last number used and click Change: the next document gets the number after it. Back returns to the settings.

Tip

To try a template without using up a number, use Preview document in the editor. A preview is never numbered; a created document always is.