This topic walks you through a very basic tutorial that create a simple report template with a few objects and some labels. This should give you a basic overview of how things work together so that you can create and use your own report templates.
In order to give you a good foundation on how to use the template editors, this tutorial shows how to create a report template from scratch. However, in practical use, you will most likely find it much easier to customize one of the standard templates to suit your needs.
Before you begin this tutorial, create a simple measurement routine that can measure four circles on a simple part. This tutorial uses the Hexagon test block (Hexblock_Wireframe_Surface.igs).
Create a measurement routine that measures four circles, similar to this.
Click on the links below to expand or collapse each step of instructions as needed. Some steps may also include a demo video of that step. For best results, maximize your help viewer before you view any videos.
Step 1: Create a Blank Report Template
Select File | Reporting | New | Report Template to access the Report Template Editor. A blank report template automatically appears.
To hide any unused toolbars, right-click on the toolbar area and remove them.
To hide any unused PC-DMIS windows, select the open window from the View menu.
Click the maximize button on the editor's window to maximize the template editor. You should see the words "REPORT" on the background of the editor, and your editor should have a "Section1" tab at the bottom. Your Report Template Editor should now look something like this:
Step 1: Report Template Editor
When working with one of the template editors, you may find it helpful to hide your usual PC-DMIS toolbars and windows, thereby freeing up some screen space. If you work frequently with templates, you may want to create a stored screen layout for your template. For information on layouts, see the "Window Layouts Toolbar" topic in the "Using Toolbars" chapter.
In addition, you may find it useful to create your own toolbar with the File | Reporting commands on it. For information on how to create custom toolbars, see the "Customizing Toolbars" topic in the "Customizing the User Interface" chapter.
Step 2: Insert and Format a Text Object for a Section Title
From the Object Bar, click on a Text object.
Insert it into the report by dragging a rectangle onto the current section. When you release the mouse, the object is selected, as shown by small green squares, called handles, at each corner of the object.
A sample Text object showing handles
Select the Text object you inserted, and drag the green handles so that it has a height of 1 inch and a length of 6 inches. Use the Ruler Bars on the top and left border of the editor as needed. Select View | Ruler Bars if the rulers aren't available.
Right-click on the Text object.
Select the BackColor property and change it to a light blue color (0.255.255).
Click the ForeColor property and change it to a dark blue color (0.0.128).
Select the BorderStyle property and change it to Normal.
Click the LineWidth property and change the value to 5.
Click the Text property and change it to "A Custom Report".
Click the Font property. The Font dialog box appears.
Change the Size to 20, the Font Style to Bold, and the Font to Arial.
Click OK.
You have formatted your text object. It should look similar to this:
Step 3: Make Properties User Assignable
Select the Text object you created in the previous step.
Right-click on the object. This causes the Properties dialog box for that object to appear on the right side of the editor. On the left side of the dialog box you will see check boxes next to most properties. These check boxes determine what properties you can make user definable.
Sample Property Sheet for a Text object. Notice the user definable check boxes on the left.
Select the check box to the left of the Text property. A User Assigned Property dialog box opens, asking you to determine the message that will prompt the user for the property value and when the user should be prompted.
User Assigned Property dialog box
In the Prompt box, type "Type Your Report's Title Now".
Select the Prompt when executing Measurement Routine option.
Click OK. The User Assigned Property dialog box closes.
Select the check box to the left of the BackColor property. In the resulting dialog box, type "Choose Your Background Color Now" for the prompt, and once more, choose the Prompt when executing Measurement Routine option.
Click OK. The User Assigned Property dialog box closes.
In this step, you selected two properties and made them "user assignable". This means whoever executes your measurement routine will be able to set these properties.
Step 4: Add a TextReportObject
From the editor's Object Bar, click on the TextReportObject icon . Your mouse pointer changes from an arrow pointer to a cross.
Add the TextReportObject on the template by dragging a box on your template's section. PC-DMIS automatically adds some default filler report text. When you apply this template to your report, PC-DMIS uses your actual report data. This filler text simply helps you understand what your design will look like. Your object should look something like this:
Sample TextReportObject
Size the object so that it's close to the width of the Text object you added earlier. To size the object, click and drag one of the green boxes (or "handles") that surround the object.
Select the Text object you added earlier. Hold down the Shift key and select the TextReportObject. This selects both objects.
With both selected, use the Layout Bar, and click the appropriate Make Same Size and Align Center icons to make the objects the same width and to align them so that they are centered in between the left and right sides of the editor.
Your template should now have a TextReportObject on the first section.
Step 5: Add a New Section to the Template
Maximize your Report Template Editor window.
Scroll to the very bottom of your template.
Right-click on the Section1 tab.
Select Add Tab from the shortcut menu. PC-DMIS inserts a new section, Section2, into your template.
Your template should now have two sections, like this:
Click on the Section2 tab to make that the active section.
From the editor's Object Bar, click the CADReportObject icon . Your mouse pointer changes from an arrow to a cross.
Drag a box on your template's section to add the CADReportObject on the template. Size the box so that it measures about six inches wide and four inches tall. Click and drag one of the green boxes surrounding the object to resize it.
When you finish drawing the box, PC-DMIS automatically displays the Label Layout Wizard. This wizard shows a fake part surrounded by some fake labels. These dummy items are simply design aids while working in the template editor. You can use this wizard to set up labels around your part. For in-depth information, see the "The Label Layout Wizard" topic. When you apply this template to your report, PC-DMIS uses your actual CAD drawing and label information.
Change the Label Count box number of labels to 4.
Change the Layout Style to Elliptical Packed.
Click on the small, square, white handle in the middle of the CAD drawing, and drag the square clockwise or counterclockwise to rotate the labels along the elliptical path.
Rotate the labels until all four are above the CAD drawing and the Layout Preview area of the Label Layout Wizard looks like this:
Layout Preview area showing four labels elliptically packed above the CAD drawing
Click OK. PC-DMIS inserts the object into Section2.
Your Section2 layout should now contain a CADReportObject looking something like this:
Example CAD report object showing the four dummy labels above the dummy part
Step 7: Define What Measurement Information Should Appear
Click on the Section1 tab and right-click on the TextReportObject you inserted earlier.
From the Properties
dialog box, change these properties:
ShowAlignments
- OFF
ShowComments
- OFF
ShowDimensions
- None
ShowFeatures
- ON
ShowHeaderFooter
- OFF
ShowMoves
- OFF
ShowScreenCaptures
- OFF
Click on the Section2 tab.
Right-click on the CADReportObject you added into Section2. The right part of the screen displays a docked Properties Sheet dialog box. This dialog box contains various properties specific to the selected object.
Click on Rules in the Rules Tree property. The Rule Tree Editor appears:
Rule Tree Editor dialog box
Rules Tree property
Expand the Features heading. A list of features appears.
Expand the Circles heading. A list of various circle features appears.
Click the Measured Circle item, and then click the Add button. This tells PC-DMIS you are adding a rule that you want the template to follow. The Edit Rule dialog box appears. This dialog box allows you to make decisions for your report template. In this case, you are telling your report template to do something when it encounters measured circles in the measurement routine's report data.
Edit Rule dialog box
Select the Use Label Template for Report option. The Label Name box becomes available for edit.
Click the ... button to open the Open dialog box that allows you to select a label template file.
Navigate to where you installed PC-DMIS, and open the Reporting sub-directory. Select the summary.lbl label, and click Open. In the Edit Rule dialog box, PC-DMIS displays the name of the template you selected. See "About Labels and Label Templates" for information and a tutorial on creating labels.
Click OK to close the Edit Rule dialog box and apply the rule. You will notice that the Measured Circle item in the list has a bold font to indicate that a rule exists for that feature type.
Click OK to close the Rule Tree Editor dialog box.
You have created a rule that tells PC-DMIS to use the summary.lbl label template to display summary information about the measured circle feature type.
Step 8: Save and Test the Template
Inside the Report Template Editor, select File | Save. In the Save As dialog box, save the template as test1.rtp.
Select File | Close to close the Report Template Editor.
Select View | Report Window. The Report window opens, showing the default report template.
From the Reporting toolbar on the Report window, click the Template Selection Dialog icon . The Report Templates dialog box opens.
Click the Add button to add your report to the Report Templates dialog box.
Navigate to and select test1.rtp, then click Open. PC-DMIS adds a thumbnail view of your report into the Report Templates dialog box.
Report Templates dialog box showing Test1.rtp
Select your template's thumbnail icon, and click Open. PC-DMIS opens the Report window using your newly created template. It should look something like this:
Report Window Showing Report Data Using the Test1.rtp Report Template
Finally, execute your measurement routine. The first time you execute the measurement routine using this report template, PC-DMIS displays a Define User Assigned Properties dialog box, asking you to give the report a new title and to set the background color.
Set these properties as desired, and click OK. The dialog box closes and PC-DMIS runs your measurement routine.
When execution finishes, PC-DMIS shows the report data with the new template.
Congratulations! You have finished the Custom Report Template tutorial.