The HotDocs Computation Archive

0054 - Referencing Multiple Choice Merge Text


Description:

How to reference multiple choice merge text to use within a computation.

 

• Code •

"«PartyName» together with «PartyGender:his/her» spouse, ..."
"«PartyName» together with «PartyGender:his/her:LIKE THIS» spouse, ..."

• Explanation •

In order to use merge text within a computation, you need to place the multiple choice variable inside of quotes and chevrons, then indicate the merge text after a colon ":". In the first example above, "PartyGender" is a multiple choice variable referencing the merge text "his/her". The second example shows how to reference both merge text and a text format.

Note that you do not have direct access to merge text while creating your computation. This can make it difficult to know the exact reference for your merge text. To find out the correct reference for merge text, insert the multiple choice variable in your document with the proper merge text selected. Now either copy the variable with its merge text and paste it in your computation, or note down exactly how the merge text is displayed in the variable name and then reproduce it in your computation.

One caution to note: If you want to use new merge text, you cannot create it by simply placing the desired merge text in your computation. You will first have to insert the multiple choice variable, with the new merge text, in your template. This "creates" the merge text. You can then delete it from the template (or cut & paste it) and place it in your computation.