Inserting Merge Codes in a Letter

Merge codes let you merge standard and custom field data from People, Mail, and Workflow records into a letter. When you print the letter, the People, Mail, and Workflow record for each person to whom the letter is going are checked, and the contents of the fields are merged into the letter.

To add merge codes to a form letter:

  1. Create the form letter.

  2. In the Edit Content view on the General panel of the record page, click where you want to place the merge code and type it. For example, to merge the person's first name into the body of the text, you would use mail.person.first.merge. To merge the person's city into the body of the letter, you would use mail.address.city.merge.

Note: You can view, copy and select merge codes on the Merge Codes panel of the Form Letter record page. After you select the merge code, click the Copy Merge Field button and then use Ctrl-V (or the right-mouse click) to paste it into the letter.

  1. Merge fields for address information or other items that would typically appear in printed mail, but not in e-mail, should be added in the Print Format panel.

  2. Select the Save and Close action to close the form letter record.

Note: Once you have placed merge codes in a form letter and used that letter in correspondence, you should not delete or add new merge codes. This might cause problems if you reprint a letter previously sent to a correspondent that has new or missing merge codes. If you want a version of the letter without or with different merge codes, you should make a new version of it.

Data Fields as Merge Codes

If you’re creating a letter that will be used with workflow, you can merge information from a workflow record. A letter can only be sent through workflow when it has a workflow code attached to it. When you assign a code to a workflow, all letters with the same workflow code will be available to send through the workflow. You can merge standard workflow fields or template-specific data fields. An example of a data field merge code would be mail.wf.udf.xxx.merge, where xxx is the name of the field you want to merge. For example, if a workflow template has a data field for Social Security Number and its field name is SSN, you can merge the correspondent’s Social Security number into a form letter by using a merge code called mail.wf.udf.SSN.merge. Note that you must use the data field's Field Name, which can be found on the Data Fields panel of the Workflow Template record. The Field Name is case sensitive when used in the merge code (mail.wf.udf.xxx.merge).

Custom Fields as Merge Codes

You can use People, Address and Mail custom fields as merge codes in a letter. If the letter is sent through workflow, you can merge custom People and/or Address fields for the Primary Person and/or a Reference. The format for the merge code for custom fields includes the ID# of the custom field. For example, if your IQ database contains a custom People field called Voter Identification and its ID# is 48, then the merge code would be mail.person.custom.48.merge.  If you wanted to use the Voter Identification custom field of the Primary Person in a workflow letter, the merge code would be mail.wf.primary.custom.48.merge.  In addition, you could use the Voter Identification of the Reference in a workflow letter with a merge code of mail.ref.1.custom.48.merge.  Note: The formats for merge codes for custom address fields are: mail.address.custom.xx.merge, mail.wf.primary.address.custom.xx.merge or mail.ref.x.address.custom.xx.merge

 

Related Topics