Xerox Paris, a document system Support & Software Mode D'Emploi

Page de 548
The PARIS Designer32 Reference Manual
221
T
H E  
P
A G E
/ P
A R A 
E
N D  
T
E X T  
B
L O C K  
E
V E N T
F U N C T I O N
An End Text Block event is a very powerful and useful event. It provides an
additional level of control over basically unformatted data and is used to force the
current text block to end and places the following printstream data into the next text
block in the page definition.
To illustrate this, we will use the example of a direct mail application that contains a
name and address plus a salutation.
Example (1):
The direct mail application requires that you create two text blocks, the
first to contain the name and address, and the second to contain the
salutation.
Often in these type of applications the name and address can vary in
length, it could be 3 or 6 lines. This means you cannot use the
maximum lines per text block to move from Text Block 1 to Text
Block 2. The solution is to use an End Text Block event.
Set up two text blocks on the page, make the first text block 10 lines
and the second text block 1 line. This means you will have more than
you want in the first text block (that is, the first name and address, the
salutation and the second name and address). Therefore, your next step
is to add the End Text Block event.
For the event, set up a test to search for the string ‘Dear’ in Text Block
1. When the test is true, the line containing ‘Dear’ will be moved to
Text Block 2 and your formatting has been achieved.