Step by Step, Example 4, Referenced Text in Static Text


This example does not introduce a new kind of element. The steps in this example will show how to handle Referenced Text in Static Text. Referenced Text will also be used with Fill-in-Text (Gaps).

First, look at this illustration and think about the question on it  “ Why not mention the number?”

To write

Write 3 Californian towns into the 3 fields 6.1 to 6.3 ....
is certainly better than
Write 3 Californian towns into the 3 fields below  ....
There are some “buts”:
1) In many cases you do not yet know the number when you prepare the Static Text.
2) The number can change when the elements are moved around and you have to change all concerned Static Text.
3) ADWorks does not mention the numbers, only ADPlayer does.

The Referenced Text of a Static Text will give a perfect solution for the problem. This description will describe the solution by modifying Document_Ex3.ADsrc. Do these steps:

- Open Document_Ex3.ADsrc and, to avoid accidents etc., save it as Document_Ex4.ADsrc.

Remember: the Document_Ex3.ADsrc is the source file and the icon is represented by a "W". The Document_Ex3.ADcomp is the compiled file and the icon is represented by a "P". These documents are on the CD in the folder Sample/Try This/FolderEx3
- Use the scrollbar to go to the Static Text we want to modify and select the element (See illustration).
- Call the definition dialog of that selected Static Text (click his Def. button). This click will lead to the RTF Editor.
- Use the Editor to modify the text like this. Modifications are:
       1) The numbers “3” are no more there,
       2) “below” has become “below1”
       3) “below2” has been introduced
       4) “Validater” became “Validater NN”.
-  Select “below1” and click on Ref. button on the Palette (See illustration).
-  Select “below2” and click on Ref. button on the Palette.
-  Select “NN” and click on Ref. button on the Palette (See illustration).
-  Leave the RTF Editor with OK.
The (font-) mode “striked out” has a special meaning in AD. It means Referenced Text. In next step we link elements to the 3 portions of Referenced Text. The link is created with the Evaluation Dialog of the Static Text.
- Call the Evaluation Dialog of the modified Static Text. (Click his Eval. See Result and indication for next step)
- Click as indicated with preceding Result. This new click leads to the Dialog Geometry and Location (See illustration). With this Dialog we choose the element to associate with “below1”. As it is the Write Text Box with Los Angeles as first item in the Evaluation Table we click on it and leave Dialog Geometry and Location with OK (You can also use double-click). See Result in the Dialog of Evaluation of the Static Text and see indication for next step.
- We proceed exactly the to same way for “below2”. Note that we do associate the same element to “below2”
- For NN we make the same operation again but we Link to the last Validater. We leave the Evaluation Dialog of the Static Text, filled like this.

The modified group can be tested (Look and refer to Exercise 1) with the menu Test Mode of ADWorks. The portions of Referenced Text looks like this under ADPlayer.

As a test: Change the number of repeating fields at Eval./Evaluation Settings. This test needs to go back to ADWorks, use the menu Back to ADWorks of ADPlayer (Look and refer to Exercice 1).
As other test: Move the elements to force the numbers to change automatically (for instance: move the group “What is the capital…” to place after the Californian question.
As third test: Add References to the the other groups.

Save the document with the command File/ Save or File/Save as. This will save a source file.
Don’t forget what you should know about compiled files (look at the end of Example 1)

On the CD you find this forth example in the folder Sample/Try This/FolderEx4/
References are added to the other groups on the document of the that folder (See illustration).
The files there are

- Document_Ex4.ADsrc  (the source file; a "W" in the icon)
- Document_Ex4.ADcomp  (the compiled file; a "P" in the icon)
Back to try this