PWI000109
this document applies to :
Gripe no 0000
PowerINSPECT 4.0 is able to generate and store results in HTML format but still has the ability to generate the report using Excel. The HTML procedure uses a template to format the output. The installation of PowerINSPECT 4.0 installs a number of pre-defined templates which have been based on the Excel templates in previous versions of PowerINSPECT. With a little knowledge of HTML, the user is able to edit or change the format to suit their own requirements.
For Excel report the concept of a template for the report was equal to the concept of a file. In the other words all the information that was needed for a report was kept in one file that was called the Excel report template. The concept of a report template for HTML reporting is different. A template is a set of files. This set is usually saved in a separate folder. It can be seen in the current implementation of HTML report and the folders like "Delcam2003" and "WebLike". By default it is assumed that there are at least three files in a template folder for example in folder Delcam2003: '''Delcam2003.pxm''', '''Layout.html''' and '''Styles.css'''. The template folder may also contain any additional files (mainly the image files) that are used in the report.
Consider files in the folder Delcam2003:
Delcam2003.pxm is the main file for the template. This file is in XML format. It stores the configuration information that creates a report using the templates you choose. The root element of the file is the "Report" tag. It has children. Each child tag name is mapped to an element in the report, e.g. the child
<Header ....>
<....>
</Header>
is mapped to the report header that is placed at the very beginning of each
report. By setting the attributes and adding sub-children you can rule how
an element is displayed, e.g. by changing the '''TemplateID''' attribute you
can choose which template is selected for the given element.
Layout.html: This file contains information about the layout
of the elements of a report. This file is in HTML format. Each element is
marked with an "id" tag. The value of the tag is related to the
value of a "TemplateID" attribute. When they match, the given
HTML element will be used for the corresponding item as configured in
Delcam2003.pxm. The HTML elements usually contain sub-elements. These
sub-elements in turn contain other sub-elements and so on. This hierarchy
creates a layout.
The "id" tag of the HTML elements can be used for several purposes.
The LayoutDefault.html and the StylesDefault.css files contain the default layout and the default css classes for HTML report. Those files are supported by developers and generally should not be used for customization. In the further versions of the report engine those classes may be included in the source code and will not be shipped separately as they are now. All customization should be possible using the files from a template. The default files can be altered when we find a bit in report layout that is likely to be the same for all the templates we create.
Note: If any element cannot be customized from the template, and you
need to change the default files, it should be considered as a bug and
reported through the normal channels.
The default layout and css files serve two needs. Firstly they allow to make
sure that any new element from the sequence tree has at least one template.
Secondly they accumulate all the design solutions that are likely to be used
in all the templates eliminating therefore the need to repeat those design
solutions in the actual templates.
If the logo needs to be changed, there are two methods that can be used. This explanation will use the files in the Delcam2003 folder.
By default, the reporting of Single Points will be in geometric format.
If the report is required in a tabulated format as for surface points, then
a different template will need to be used. This template is accessed from
the TemplatePerItem folder. In this folder, select the file
TemplatePerItem.pxm to generate the results for Single Points in tabulated
format. To keep the output generated neat, the Single Points sequences are
better kept in their own Geometric Group.