Use Includes
KCM Designer is all about reusable content. Different Master Templates can make use of single functions and procedures, such as date and address. When working with Master Templates, you can refer to these functions instead of writing them manually every time. For that, use Includes – these are KCM objects containing functions and procedures that can be reused in multiple Master Templates. Includes are compiled in Master Templates.
In KCM Designer, when a change is applied to an Include, it affects each Master Template that makes use of this Include. To prevent errors, we recommend that you recompile a template after an Include is updated.
Create, view, and edit Includes
You can create, view, and edit an Include in KCM Designer, automatically opening Microsoft Word.
-
Navigate to
.
-
Click
Includes and then click
New Include in the
New pane on the right.
The New Include window appears.
- Enter a name for the new Include and click OK.
-
Click the new Include and then click
Edit in the
View and Edit pane on the right.
-
To view the content, click
View.
The Include opens as a read-only document in Microsoft Word.
If you edit the file in this mode, it can only be saved to a local storage.
-
To edit the content, click
Edit.
The Include becomes fully available for editing in Microsoft Word. If you did not have an "In development" revision, it is created. On save, the "In development" revision will be updated.
-
To view the content, click
View.
-
Add or paste necessary code and close Microsoft Word. If an error occurs, click
View error document.
To attach an Include to a document, see the next section.
Attach an Include to Master Template
- Navigate to .
-
Select the
Master Template to attach an Include and then click
Edit in the
View and Edit pane on the right.
Master Template opens in Microsoft Word.
- Create a new paragraph where you need to insert an Include, place the cursor in the new paragraph, and type __INC(the name of the Include).
- Add all the needed __INC instructions and close Microsoft Word.
- Save the changes when prompted to do so.