Add a condition to a Field

You can apply conditional formatting to a Field. For example, this may be useful to ensure that the name of the client is always preceded by Mr., Mrs., or Ms. The following procedure explaining how to add Mr. or Mrs., depending on the addressee's gender.

  1. Navigate to Content > Text Blocks.
  2. Click the Text Block to edit and then click Edit in the View and Edit pane on the right.

    The Text Block Editor appears.

  3. Place the cursor where you want the name of the customer to appear. From the Fields list on the right, find and double-click the Fields [Customer.Initials] and [Customer.Surname] if they are not there.
    The Fields appear in the text.
  4. Place the cursor before the [Customer.Initials] Field and add the [Customer.Gender] Field.
    The Field appears in the text.
  5. Click the [Customer.Gender] Field in the text and then click the F button on the toolbar.
  6. From the drop-down list, select Condition.
    For the Compare with parameter, enter M (for male).
    For the Use if matches parameter, enter Mr.
    For the Use otherwise parameter, enter Mrs.
  7. Click OK.
    If the value for gender is M, the Text Block uses Mr. If the value is not M, Mrs. is used.
  8. Click Save & Close.

Test a conditional Field

If you applied a condition to a Field, test a Text Block it belongs to.

  1. Navigate to Content > Text Blocks.
  2. Click any Text Block to which a conditional Field belongs and click Test in the Other Actions pane on the right.

    The Test window appears.

  3. Select the status In development and the needed Document Template.
  4. Click Edit Test Data.
    The Test window appears.
  5. In the Customer field, enter M or F for Mr. or Mrs., as applicable.
  6. Click Test.
    The document opens in Microsoft Word. Check if the conditional Field appeared correctly.
  7. Close Microsoft Word.