Run function in stacking

The Run function performs these actions for the stacking component:

  1. Moves the input envelopes records to the Busy status.
  2. Batches envelopes into stacks.
  3. In each created stack, it sorts the envelopes according to the configured sorting criteria
  4. Puts all envelopes with the same channel and the same printer in the same stack. The organizational metadata values shared by all envelopes are taken over in the stack.
  5. Writes the created stacks to the run-time database with stack type "Streaming (20)." It also performs these steps:
    1. Moves the input envelopes to the Finished status.
    2. Updates the input envelopes with the stack.

Parameters

The Run function does not have any input parameters. It selects envelopes from the run-time database, according to the configured selection criteria. Only envelopes in the Waiting status are considered for selection.

Result

The Run function returns the number of created stacks.

If an error is encountered, the Run function moves the input envelopes to the Error status.