Where can Variables be Placed
All User Variables in Document Publisher can be used throughout the template. You can use the variables within Headers, Footers, boilerplate text and document titles.
What are Variables?
The Variables store bits of data to be used in tags that allow the use of either a variation of data or static data.
For example the variable $UserName is static will only output the currently Logged in Users Name within the document. The User Name will also be output if the template is being generated through the Phase sidebar in WorkBench.
Some variables can be used to hold items identities in a static list like $IDList or lists of item identities collected from Hierarchy Tables like $ItemList. The lists for $ItemList can change depending on cross references and/or if the template uses parameters.
Creating User Variables is easy. Read How to Create a Variable to find out.
User Variables in Headers and Footers
The variable tags can be used within a Header and/or Footer in conjunction with Microsoft® Word’s own data fields.
In the Word tab, select the Header or Footer option. Then select the Edit Header/Footer option. Once the Header/Footer is open, select the User Variable button and the variable you wish to use.
Several variable tags can be placed to output within the Header/Footer so you get the output required. These tags can also be formatted.
When editing the Header or Footer the View will change to Print View as they don’t show in Draft view.
The final output looks like this:
User Variables in Boilerplate
The variable tags can be placed within any boilerplate text. This allows for changes in data like the date or user publishing the document.
User Variables in Title Text
A User Variable or a Paragraph Group tag can be used to set the Document Title. A variable is quicker but does not allow for parameters are used in a field tags.
So the output looks like this:
Or you can have the Title only output when you are generating a Formal Document. Use any of the $FormalDoc variables and they are only generated during a Formal Publish. In this example I have used $FormalDocTitle:
Using $FormalDocTitle means the title will output as to the same as the User entered in the Title in the Publish Formal Document UI.