Example showing the button to use to change the report header's graphic

## Modifying the Report's Header

Many users want to change the header in some way, usually to modify the default graphic that appears in the default report's header to something more company-specific. You can change the header graphic by following this procedure. You can change other information by similarly modifying the appropriate templates.

Your report template (by default this is TEXTONLY.RTP) calls a label template to display the header information (by default this is FILE_HEADER.LBL). So, this is the file you will need to modify.

1. Remove the Read-only attribute from the template file.

2. Open the file in the Label Template editor.

   - Select File | Reporting | Edit | Label Template. An Open dialog box appears.

   - Select the FILE_HEADER.LBL template and click Open.

   - In the Label Template Editor you should now see the edit area filled with a GridControlObject. This object controls all the header data that you see in the report.

3. Change the graphic.

   - Double-click on the GridControlObject. You will see a hash border around the object. This tells you that you can edit the code or items inside of the header.

   - Right-click on the PC-DMIS graphic and a Grid Properties dialog box appears.

   - In the Cell tab, click Select. An Open dialog box appears.

   - Navigate to the graphic image you want in the header, select it, and click Open. The dialog box closes.

   - Click Apply. The new graphic appears in the cell.

4. Save and test the modified label template.

   - Once you have things as you like it, click OK, and then select File | Save to save your changed Label Template.

   - Select File | Close to close the Label template editor, returning to your part program.

   - Select View | Report window. If your change doesn't immediately appear, select the Redraw the report icon from the Reporting toolbar.

Converting LOGO.DAT, HEADER.DAT, and ELOGO.DAT Keywords

In versions prior to 4.0, these .DAT files contained # keywords that defined the information that would appear in your report's headers and footers (see "Modifying Headers and Footers" in the "Using the Edit Window: Introduction" section). In versions 4.0 and later, PC-DMIS uses Report Expressions to accomplish the same thing. The following table details the Report Expression—or where applicable the report object—to use and where to use it.

.DAT # Keyword | Functionality | Equivalent Command in Report Template
#DATE | Inserts the current date. | =SYSTEMDATE("MMMM dd, yyyy")
#TIME | Inserts the current time. | =SYSTEMTIME("HH:mm")
#PAGE | Inserts the current page number. | =Page()
#TRn | Inserts the value of trace field n, where n is the trace field number. | =TRACEFIELD(n)
#PARTN | Inserts the part program name. | =PARTNAME( )
#DRWN | Inserts the revision number. | =REVNUM()
#SERIALN | Inserts the serial number. | =SERNUM( )
#SEQUENCE | Inserts the sequence number. | (Not applicable)
#SHRINK | Inserts the scale factor. | =MEASSCALE()
#NMEAS | Inserts the total number of dimensions. | =NUMMEAS()
#NOUT | Inserts the total number of dimensions that are out of tolerance. | =NUMOUTTOL()
#ELAPSTIM | Inserts the time elapsed between start and end of execution. | =ELAPSEDTIME()
#BMP=bitmappath | Inserts a bitmap of the specified full path and name. | Use Bitmap object

See "About Report Expressions" for using other expressions in your report templates.

See "Displaying a Variable's Value" for limitations on using variables inside report headers.