Page 1 of 8
Document assembly using NoteTab clips Fookes Software's NoteTab, found at http://www.notetab.com, is a Notepad replacement which stuffs a large number of features into a small and low-cost package. One of its most powerful tools is the ability to create "clips", which are collected in libraries called "clipbooks". The output that it creates will always be in straight ASCII format, which can then be pasted or inserted into any word processor or other program for further editing and refinement. NoteTab's clip language includes several features and tools which are similar to VisualBasic scripts and the macro programming language used with WordPerfect. By using some of the fields and variable assignment commands, a handy document assembly package can be developed. The clip language, like a programming language, includes commands, functions, variables, and labels. Each of them can help to assemble the final document.
Field input The simplest tool is the field input. Just like a blank in a paper form, a field input code invites the user to enter a string of text and then it incorporates the string in the output text. A field in a NoteTab clip is defined by the expression "^?[string]", where the string is a prompt to the user, such as "^?[Enter desired text]". When this sequence appears, NoteTab will create and display a dialog box, called a "Clip Wizard", with the string as a prompt and an edit box for the value to be entered by the user. Whatever is entered will be transmitted to the final document. This is the key to document assembly. A major advantage of the NoteTab clip language over sophisticated macro languages is that the Clip Wizard is automatically constructed. There is no need to define or to create a dialog box, to position the box or to define its size; the clip language does it for you. There are other codes which may be used. If a " = " is placed after the prompt string, the text placed after it will be the suggested value. To create a combo box, use a special code "T=C", a double " == ", and list more than one item after that paired code, separated by the " | " character. Any item preceding by an underscore will be the default suggested value. To create a list box, do the same, but use the special code "T=L". The following four lines use all four types of edit input boxes: ^?[Name of defendant1] ^?[Name of defendant2=John Smith] ^?[(T=C) Name of defendant3==John Smith|Joe Jones|_Monica Lewinsky] ^?[(T=L) Name of defendant4==John Smith|_Joe Jones|Monica Lewinsky] The Clip Wizard for this code renders as follows:
file://C:\Temp\clipdocassembly.htm
4/7/2007
Page 2 of 8
The four fields shown are: l l l l
a plain input field a plain input field with a suggested value a combo box, with several possible values a list box with the same possible values
A CaseCite clip Each separate item, in the form "^?[Text prompt]", displays a separate input field on a separate line within the dialog box. The following rather simple-appearing clip language allows the user to enter various items and then constructs a case citation, using proper Blue Book citation format: ^?[Name of plaintiff] v. ^?[Name of defendant], ^?[Mich Vol no.] ^?[(T=C)Mich Source=Mich.|_Mich.App.] ^?[Mich Page], ^?[NW Vol no.] ^?[NW Source=N.W.2d] ^?[NW Page] (^?[Year=2000]) The ClipWizard created by this clip is as follows:
file://C:\Temp\clipdocassembly.htm
4/7/2007
Page 3 of 8
Note that some fields have pre-suggested entries, while others do not. After the fields are filled in, it looks like this:
file://C:\Temp\clipdocassembly.htm
4/7/2007
Page 4 of 8
The resultant text reads as follows: Smith v. Jones, 123 Mich.App. 456, 78 N.W.2d 479 (2002)
Document assembly - a simple example Document assembly is accomplished by combining plain text entries with clip fields. The primary fillins are three Ps - pronouns, plurals, and possessives - and verb tenses. We will use both a simple and a complex example to demonstrate each. The code for one paragraph of a contract might be: The Agent agrees to pay $^?[Enter amount, without dollar sign] to the ^?[(T=C)Singular or plural==_client|clients], and in consideration thereof the ^?[(T=C)Singular or plural==_client|clients] ^?[(T=C)Do/does==_does|do] agree that ^?[(T=C)Pron1==_he|she|they|it] will release the Agent from any further responsibility or liability in connection with the Project. The code for the edit fields could include: for pronouns:
file://C:\Temp\clipdocassembly.htm
4/7/2007
Page 5 of 8 ^?[(T=C)Pron1==_he|she|it|they] ^?[(T=C)Pron2==_him|her|it|them] for verb tenses, a simple prompt at the end of the verb root: understand^?[Enter s for singular, nothing for plural] for irregular verb tenses, the whole verb and a combo box are used: ^?[(T=C)Have==_has|have] ^?[(T=C)Do/does==_does|do] ^?[(T=C)Is/are==_is|are]
A complicated example - answer to complaint Consider the following different responses that might be made to a single paragraph of a complaint, depending on sex and number of plaintiffs and of defendants: The defendant neither admits nor denies the allegations of this paragraph because they do not apply to him, and plaintiff is left to his proofs. The defendant neither admits nor denies the allegations of this paragraph because they do not apply to her, and plaintiff is left to his proofs. The defendants neither admit nor deny the allegations of this paragraph because they do not apply to them, and plaintiff is left to its proofs. The defendant neither admits nor denies the allegations of this paragraph because they do not apply to him, and plaintiffs are left to their proofs. In constructing an answer to a complaint, there are four different possibilities for the plaintiff - man, woman, neutral, plural - and the same four for the defendant as well. For each possibility, for example, the following have to be assigned: Nominative Verb tense Possessive Pronoun Object pronoun Possessive pronoun
The defendant admits The defendant's he him his
The defendants admit The defendants' they them their
Under our system, the clips that create the various paragraphs are preceded by a series of inquiries, using a Clip Wizard for entry by the user, the answers to which define a series of variables. The variables are then used to fill in the text where applicable. Although we cannot provide the entire coding sequences, not wanting to reveal trade secrets, we can provide the following sequences for the creation and assignment of the variables: ^!Set %defname%=^?[Enter name(s) of defendant(s)] ^!Set %psex%=^?[(T=C)The plaintiff is==_Man|Woman|Corp|More] ^!Set %dsex%=^?[(T=C)The defendant is==_Man|Woman|Corp|More]
file://C:\Temp\clipdocassembly.htm
4/7/2007
Page 6 of 8 This rather simple code displays as the following.
The hard work is then done after these values have been created, by the following series of commands which incorporate labels and flow commands as well as the "!Set" command to define variables. The variables are then used for final document assembly. :First ^!If ^%psex%=Man ^!GoTo PMan ^!If ^%psex%=Woman ^!GoTo PWoman ^!If ^%psex%=Corp ^!GoTo PCorp ^!If ^%psex%=More ^!GoTo PMore :Pman ^!Set %pron%=him ^!Set %pposs%=his ^!Set %pl%=plaintiff ^!Set %pls%=plaintiff's ^!GoTo Second :PWoman ^!Set %pron%=her ^!Set %pposs%=her ^!Set %pl%=plaintiff ^!Set %pls%=plaintiff's ^!GoTo Second :PCorp ^!Set %pron%=it ^!Set %pposs%=its ^!Set %pl%=plaintiff ^!Set %pls%=plaintiff's ^!GoTo Second :PMore ^!Set %pron%=them ^!Set %pposs%=their ^!Set %pl%=plaintiffs ^!Set %pls%=plaintiffs' ^!GoTo Second :Second ^!If ^%dsex%=Man ^!GoTo DMan
file://C:\Temp\clipdocassembly.htm
4/7/2007
Page 7 of 8 ^!If ^%dsex%=Woman ^!GoTo DWoman ^!If ^%dsex%=Corp ^!GoTo DCorp ^!If ^%dsex%=More ^!GoTo DMore :Dman ^!Set %dpron%=him ^!Set %dposs%=his ^!Set %td%="this defendant" ^!Set %td2%="This defendant" ^!Set %s%=s ^!Set %y%=ies ^!Set %do%=does ^!GoTo End :DWoman ^!Set %dpron%=her ^!Set %dposs%=her ^!Set %td%="this defendant" ^!Set %td2%="This defendant" ^!Set %s%=s ^!Set %y%=ies ^!Set %do%=does ^!GoTo End :DCorp ^!Set %dpron%=it ^!Set %dposs%=its ^!Set %td%="this defendant" ^!Set %td2%="This defendant" ^!Set %s%=s ^!Set %y%=ies ^!Set %do%=does ^!GoTo End :DMore ^!Set %dpron%=them ^!Set %dposs%=their ^!Set %td%="these defendants" ^!Set %td2%="These defendants" ^!Set %s%= ^!Set %y%=y ^!Set %do%=do :End
For each clip, combinations of text and code, with the code incorporating the variables, are used. The code consists of the introductory "^" followed by the variable name contained between two "%" characters. A sample code that would use a variable is as follows: ^%td2% rel^%y% on the good faith of the parties to ensure that proper procedures are followed. The variables are "td2" and "y". The possible values for "td" are "This defendant" and "These defendants", and the possible values for "y" are "ies" and "y". Thus the final output would be one of the following:
file://C:\Temp\clipdocassembly.htm
4/7/2007
Page 8 of 8 This defendant relies on the good faith of the parties to ensure that proper procedures are followed. These defendants rely on the good faith of the parties to ensure that proper procedures are followed. Using these sequences as patterns, you can adapt NoteTab's clip language to your own form documents.
file://C:\Temp\clipdocassembly.htm
4/7/2007