Microsoft Office Tutorials and References
In Depth Information
Adding information with rules
8 In the Insert Word Field: If dialog box, select a merge field in the
Field Name list box, select a condition in the Comparison box
and, if necessary, enter a value in the Compare To list box. In the
Insert This Text box, enter the result that the field will display if the
comparison is true. In the Otherwise Insert This Text box, enter the
result that the field will display if the comparison is false. Click OK.
9 If you want to base the decision on a bookmark value (such as one
in a SET field or an ASK field), click the Insert tab. In the Text group,
click Quick Parts and then click Field. Continue at step 10.
10 In the Field dialog box, in the Field Name list box, click If. Then, click
the Options button.
In the Field Options dialog, click the desired bookmark name and
then click Add To Field. Click at the end of the expression in the
Field Codes box and type the rest of the code.
For example, suppose the selected bookmark is Quantity, and you
want the result to display copy if Quantity is 1 or copies if Quantity
is greater than 1. The completed code for this field is IF Quantity =
1 “copy” “copies” .
Click OK in the Field Options dialog box and then click OK in the
Field dialog box.