Adding an include file element
Use the include file template element to attach or link
to external files from your report.
About this task
You can choose to link the file or physically embed the file into your output document. However, the way that include file elements are handled depends on the output format and the location from which you are retrieving the file.
Physically embedding files
About this task
When you are selecting files from a local or remote location:
- For HTML,and XSL-FO outputs, the included file is always a hyperlink.
- For PDF output, the included file is imported and the full contents of the document display.
- For Microsoft Word output, Rational® Publishing Engine updates Microsoft Word fields automatically during document generation. If an INCLUDE TEXT field is generated, the macro did not run and the task of importing the file is delegated to Microsoft Word. An include file is not visible in the output document until all fields are updated. To update the fields, use the Update Fields feature in Microsoft Word or use the macros that are contained in the RPE_HOME\utils\word\rpe.dot style sheet.Tip: A Microsoft Word document that links to other files is not self-contained. Moving the document on other computers prevents you from visualizing the content of the linked documents. If visualization is needed, use the Break links feature in Microsoft Word to include the contents of a linked file.
Procedure
Dynamically referencing files
Before you begin
Important: Use physically embedding instead of
dynamically referencing when:
- A template or snippet is designed to extract information from a data source.
- A template or snippet contains a dynamic reference in it.
About this task
When you are selecting files and dynamically referencing
them:
- For Microsoft Word
output, Rational Publishing Engine updates Microsoft Word fields automatically
during document generation. If an INCLUDE TEXT field
is generated, the macro did not run and the task of importing the
file is delegated to Microsoft Word.
An include file is not visible in the output document until all fields
are updated. To update the fields, use the Update fields property
in the document specification, Update Fields feature in Microsoft Word, or the macros that are
contained in the RPE_HOME\utils\word\rpe.dot style
sheet. Important:
- Do not use the Update fields property when you are generating exceptionally large documents. Large documents might be unable to generate with the property set and could result in an out of memory error.
- Do not run a macro to update the fields if you are referencing documents from a secured location. The authentication process cannot be completed and causes the macro to hang.