3 Examples with quite some variation in here:

  1. Count how often the word confidential is used and if more then 10 times do...
  2. Count manually the pages, and insert a form feed character, as in that ASCII file are no form feeds included
  3. Workload Job Rotation sends the jobs alternating to X printers, one after the other

Other examples and the full description can be found

1. Count how often the word confidential is used and if more then 10 times do...


; Whatever you need



; define the starting variables:


[When the word confidential is found]



[if it was found more then 10 times]

; Primary trigger always true


; Now when more then 10 times


; Archive a copy to boss


2.: We have an ASCII data stream with 55 lines per page, but without form feeds. We need to insert

  1. on the first always the Letterhead (form 500)
  2. on the last page a special Terms and Condition form goes on the back (form 501)
  3. on all the pages between only the logo (form 502)

If the document already contains form feeds all examples below the #MyFFcounter# can be replaced by #PREPARSEPAGECOUNT# and the insertion of the form feed rule can be erased. Be sure that in rule GLOBAL the key PreParsing=On is set.

2.1 First method to solve the clients requirements

Note: PreParsing with #PREPARSEPAGECOUNT# will not work, as there are no Form Feeds in the data stream. So ELP has to count the rows while reading in and add at the proper place a form feed.


; Whatever you need...


; create and set the own made page counter to initialize 0

[Insert form feed @ Line 55]


; In every Row 55


; add \x0C -> ASCII 12 -> form feed and restart counting rows


; and increase the own made page counter

[The rule if counter minimum 1]


; Primary trigger is mostly always true, as a 1 is normally always found in the stream.

; otherwise use key SetTrigger in rule Global


; trigger this rule only if minimum one page is found.


; Then use this ELP command

; C1:1F500S0; put full letter head on all pages and print simplex (S0)

; C1:#MyFFcounter#F501FFF501; On the last page put the Logo as well, insert a form feed and put T&Cs on back

; C1F502; on all pages in between and the first and the last one put the logo only.
; Note: C1:#MyFF must be at the beginning, as if a document is only one page, the C1:1 will NOT be performed

Tip: Often you have to convert a matrix printer data stream to a laser printer stream. Unfortunately the matrix printer has some more lines to print on a longer the A4 Paper. here is what to do, if the software can't be told to reduce the amount of lines per page:

a) If it is a pure ASCII Stream, you may use the ELP_Command with ELP_INIT_JOB key to reduce the vertical motion index.

b) if you have some blank rows at the end on each page, set the vertical motion index to 0 and expand it after the form feed to whatever you need.

[Set 0 lpi (lines per inch) on row 64]



[Insert Form Feed @ Line 72 and set VMI to 6 lpi]



2.2 Another way is to print the terms and condition on the first page, Then no counter is needed



; C1:1S0F500; on page 1 add the Letterhead and set to duplex printing

; C1:2F501; Insert on new page 2 the T/Cs.

; C1F502; On all remaining pages, print the logo.

[Insert Form Feed @ page 55]




Related articles: Rules theory, Rule assistent, Add key to rule , Forms management, ELP_Commands, Variables in ELP