Document Assembly Lexicon

Each document assembly product has its own particular way of doing things, and with that goes differing syntax, that changes from product to product. For example, if you are used to HotDocs, you would be familiar with –conditional text—-alternate conditional text–. If you attempted to do this in GhostFill you would quickly find that GhostFill does not utilize ELSE or ELSE IF statements. The purpose of this lexicon is to provide a comparison table between the more popular document assembly products on the market.

We have adopted a navy colored Courier font type for code quoting, which will appear in the 3 columns on the right side of the table. Any code quote that appears in a paler blue is a direct link to an equivalent entry on our glossary page for that specific product.

Document Assembly Software Syntax






AscendReturn the items in a collection in ascending order{= ASCENDING( SelectVariable1 ) | PARAGRAPH}ASCEND%[List.SortByResult(True)]
AttachmentsFrom the main template, will cue up another template for assembly after completion of the master template.{attach TEMPLATE_NAME} «ASSEMBLE “TemplateName”»%[Templates.Run(‘TemplatePath’, ‘TemplateName’)]
Boolean LogicRules created that are based on true/false or yes/no variables Var Name TF IS TRUE Var Name TF IS FALSE«IF Var Name TF» «IF Var Name TF = FALSE»%[KeepBlockIf( Var Name TF )] %[DeleteBlockIf( Var Name TF )]
CalulationsAllows the developer to apply mathematical and string formulas on answer data.{= Var NameNU * 1.175}.«Var NameNU * 1.175»%[Var NameNU * 1.175]
Conditional TextUse to distinguish optional text from boilerplate in a document.[Var Name IS “ABC” ……]” «IF Var Name = “ABC”»….«END IF» %[KeepBlockIf(Var Name = “ABC”)] … %[EndBlock]
ContainsAt times you will need to test whether a variable contains a value.{= CONTAINS( StateMC, “NY” )}«IF StateMC CONTAINS “NY”»%[KeepBlockIf( InStr( “NY”,StateMC ))]
Count of a CollectionThe number of items in a collection{= COUNT( Var Name TE )} «COUNT(DIALOG RPT)»%[Collection.Count]
Cross-References and Paragraph LabelsFeature that serves as a front-end to MS Word internal cross-referencing PARTIESText of Paragraph ……… . Text of paragraph refers to {ref PARTIES}.No equivalent. Depends on Word field coding.No equivalent. Depends on Word field coding.
Date FormattingAllows the user to change the way a date field is displayed in a document {Date:ThisAgreement | “[dd]/[mm]/[yyyy]” }.«Var NameDA:Jan 2, 2004»%[FormatDate(Var Name, ‘mm dd, yyyy’)]
DescendReturn the items in a collection in descending order{= DESCENDING( SelectVariable1 ) | PARAGRAPH}DESCEND%[List.SortByResult( False )]
Drafting NotesIn preparing a template the author may wish to leave annotations in the document that are removed during assembly.{note Comment ….}«CT // Comment ….. »%[ | Comment … ]
Dynamic PromptsPrompts in HotDocs, GhostFill and DealBuild allow the developer to add variables to modify the prompts at runtime.Prompt: CHECK box if {Var Name TE} is healthy?Prompt: CHECK box if «Var Name TE» is healthy?%[ThisDialog._Form.Fields.Var Name TF.DisplayName = “CHECK box if ” & ThisDialog.Var Name TE & “is healthy?”]
IF, then ELSE statementStructure for including alternative text{= IF( Var Name TF, “then”, “else” )} «IF Var Name TF=TRUE»Text if true«ELSE»Text if false«END IF»%[IfTrue ( Var Name TF, “then”, “else” )]
Merge TextSupports multiple merge text options for a lookup table.Var Name.ValueColumn. ReturnValueColumn«Var NameMC:MergeText» LookupLST contains option and result.
Multiple Choice LogicRules created that are based on selection or choice variablesVar NameMC IS “Value”«IF Var NameMC = “Value”»%[KeepBlockIf( Var NameMC = “Value” )]
Number FormattingAllows the user to change the way a number field is displayed in a document {SettlePaymentDays | WTH UPPER}«Var Name NU : NINE»%[NumberToWords( Var Name )]
Numeric LogicRules created that are based on number variablesVar NameNU IS MORE THAN 1 Var NameNU IS AT MOST 8«IF Var NameNU > 1» «IF Var NameNU <= 8»%[KeepBlockIf(Var Name NU > 1)] %[KeepBlockIf(Var Name NU <= 8)]
Selected item in a CollectionReturn the Nth member of a collection{= MEMBER( Var Name, 1 )}«Var Name[1]»%[Collection.Var Name TE[1]]
SubassembliesSubassemblies can be called, with some discretion as to naming the output document{attach TEMPLATE_NAME AS MyDocument}«ASSEMBLE “TemplateName” /stw /of = “MyDocument”»%[Templates.SaveAndRun( TemplatePath, TemplateName, True, DocumentPath, DocumentName )]
SubdocumentsFrom the main template, these command will insert another template into the document at the fillpoint. {include TEMPLATE_NAME} «INSERT “TemplateName”»%[Templates.Select( ‘TemplatePath’, ‘TemplateName’ )]
Text FormattingAllows the user to change the way a text field is displayed in a document{Var Name | CAPITALS }.«Var Name TE:LIKE THIS»%[UpperCase( Var Name TE )]
Variable TextVariable text takes the result of a prompt or script and places it in the document.{Var Name}«Var Name TE»%[Var Name] %[Dialog.Var Name] %[Profile.Var Name] %[Object.Var Name]