Reference Variables in a Word Object
In a Word object in CDM, you can reference variables such as source-destination variables, named range variables, and image range variables that you have defined in an Excel object. You can also reference a chart or picture from an Excel object in a Word object.
Reference a Chart in a Word Object
In a Word object in CDM, you can reference a chart from an Excel object.
In the source Excel object, you must have defined a chart. See Add a Chart to an Excel Object.
- Open the report that you want to work with.
- Open and check out the Word object that you want to edit.
- Click the Section View Mode icon in the status bar.
- Position the pointer where you want the chart to appear in the Word object.
Tip: You can also create a table or text box and make it the size you want the chart to be displayed and position the pointer inside of it.
- Click the Report Object tab on the ribbon, then click Insert Variable > Chart. The Reference Variables window opens, displaying all chart variables in the report.
- Select the chart variable you want to use and from the Insert as Chart button drop-down menu select one of the following options:
- Insert as Chart - Use this option to import a chart in its original size.
- Insert as Chart and resize - Use this option to import a chart into the table or text box you have created. Make the table or text box bigger or smaller depending on the size of chart you want displayed.
A hyperlink to the chart is inserted.
- Save your changes to the Word object.
- Click the Default View Mode icon in the status bar.
- Save your changes to the report and check in the Word object.
After you generate the document, the chart defined in the Excel object will resolve in the Word object with the original formatting.
Reference a Picture in a Word Object
In a Word object in CDM, you can reference a picture from an Excel object.
In the source Excel object, you must have inserted a picture. If you format the picture by entering an ALT Text description for it, this description is then used to identify the picture by name in the Reference Variables window. If no ALT Text description exists, the file name of the picture is used to identify the picture.
To reference a picture from an Excel object in a Word object:
- Open the report that you want to work with.
- Open and check out the Word object that you want to edit.
- Click the Section View Mode icon in the status bar.
- Position the pointer where you want the picture to appear in the Word object.
Tip: You can also create a table or text box and make it the size you want the picture to be displayed and position the pointer inside of it.
- Click the Report Object tab on the ribbon, then click Insert Variable > Picture. The Reference Variables window opens, displaying all picture variables in the report.
- Select the picture variable you want to use and from the Insert as Image button drop-down menu select one of the following options:
- Insert as Image - Use this option to import a picture in its original size.
- Insert as Image and resize - Use this option to import a picture into the table or text box you have created. Make the table or text box bigger or smaller depending on the size of picture you want displayed.
A hyperlink to the picture is inserted.
- Save your changes to the Word object.
- Click the Default View Mode icon in the status bar.
- Save your changes to the report and check in the Word object.
After you generate the document, the picture inserted in the Excel object will resolve in the Word object.
Reference a Source-Destination Variable in a Word Object
In an Word object in CDM, you can reference a source-destination variable in an Excel object.
In the source Excel object, you must have defined a source variable.
- Open the report that you want to work with.
- Open and check out the Word object that you want to edit.
- Click the Section View Mode icon in the status bar.
- Position the pointer in the Word object where you want to insert the destination variable.
- Click the Report Object tab on the ribbon, then click Insert Variable > Source-Destination. The Reference Variables window opens, displaying all destination (
##D<varname>) and global destination (##GD<varname>) variables that have a corresponding source (##S<varname>or##GSD<varname>) variable defined in CDM. - Select the destination variable you want to use and click Insert. The destination variable is inserted into the Word object.
- Save your changes to the Word object. The data defined in the value of the source variable is copied into it.
- Click the Default View Mode icon in the status bar.
- Save your changes to the report and check in the Word object.
Reference a Print Area Named Range Variable in a Word Object
In a Word object in CDM, you can reference a print area named range variable in an Excel object.
In the source Excel object, you must have defined a print area named range variable for a cell range.
- Open the report that you want to work with.
- Open and check out the Word object that you want to edit.
- Click the Section View Mode icon in the status bar.
- Position the pointer where you want the print area named range variable to appear in the Word object.
- Click the Report Object tab on the ribbon, then click Insert Variable > Named Range. The Reference Variables window opens, displaying all print area variables.
- Select the print area named range variable you want to use and click Insert as Hyperlink. The print area named range variable is inserted into the Word object.
- Save your changes to the Word object. The data defined by the print area named range variable is copied into it.
- Click the Default View Mode icon in the status bar.
- Save your changes to the report and check in the Word object.
Reference a Named Range Variable in a Word Object
In a Word object in CDM, you can reference a named range variable that was created within a print area in an Excel object.
In the source Excel object, you must have defined a name range variable for a cell range within a print area.
- Open the report that you want to work with.
- Open and check out the Word object that you want to edit.
- Click the Section View Mode icon in the status bar.
- Position the pointer where you want the destination named range variable to appear in the Word object.
- In the Report Object tab on the ribbon, click Insert Variable > Named Range. The Reference Variables window opens, displaying all print area variables.
- Select the print area variable that contains the named range variable you want to use, click the Insert as Hyperlink drop-down arrow, and select Insert Print Area Named Ranges.
- A window is displayed, listing the named range variables that have been defined within the print area you selected in the Reference Variables window.
- Click on a named range variable and it is inserted into the Word object.
- Save your changes to the Word object. The data defined by the source named range variable is copied into it.
- Click the Default View Mode icon in the status bar.
- Save your changes to the report and check in the Word object.
Reference an Image Range Variable in a Word Object
In a Word object in CDM, you can reference an image range variable in an Excel object. The image range can contain either a graphic or data that is rendered as an image in Word.
In the source Excel object, you must define an image range by using the image range start (##IRS) and image range end (##IRE) variables. The image range can contain data or a graphic. If you have specified a choice in the Zero Amount Shown As report property, or if you have specified rows or columns in the Excel object that you want to show or suppress, your choices might affect the appearance of the image that you create.
To reference an image range variable from an Excel object in a Word object:
- Open the report that you want to work with.
- Open and check out the Word object that you want to edit.
- Click the Section View Mode icon in the status bar.
- Position the pointer where you want the image range to appear in the Word object.
Tip: You can also create a table or text box and make it the size you want the image to be displayed and position the pointer inside of it.
- Click the Report Object tab on the ribbon, then click Insert Variable > Image Range. The Reference Variables window opens, displaying all image range variables in the report.
- Select the image range variable you want to use and from the Insert as Image drop-down menu select one of the following options:
- Insert as Image - Use this option to import a referenced image range that contains only data (no pictures or charts). The data is converted into an image that contains only the cell data (in effect, numbers or text). This option causes changes to suppression and zeroes. The image is generated according to the default size of 150 DPI.
- Insert as Image and resize - Use this option to import a referenced image range that contains only data (no pictures or charts) into a table or text box you created and sized. The data is converted into an image that contains only the cell data (in effect, numbers or text). This option causes changes to suppression and zeroes. The size of the generated image fits the size of the table or text box you have created. Make the table or text box bigger or smaller depending on the size of image you want displayed.
- Insert as Snapshot - Use this option to import a referenced image range that is an exact snapshot of the image range you specified, which can include data, pictures and charts, or just pictures and charts. The range is converted to an image according to the default size of 150 DPI.
- Insert as Snapshot and resize - Use this option to import a referenced image range that is an exact snapshot of the image range you specified, which can include data, pictures and charts, or just pictures and charts, into a table or text box you created and sized. The size of the generated image fits the size of the table or text box you have created. Make the table or text box bigger or smaller depending on the size of image you want displayed.
A hyperlink to the referenced image is inserted.
- Save your changes to the Word object.
- Click the Default View Mode icon in the status bar.
- Save your changes to the report and check in the Word object.
After you generate the document, the image range defined in the source Excel object will resolve in the Word object.
Preview Variables in a Word Object
You can preview variables that are displayed as unresolved in a Word object in CDM.
When a Word report object is opened, variables in the object are displayed by default as resolved (that is, they are shown as they will look when the report is generated). However, if you have selected Open or Edit as the setting in the Report Object Double Click Action checkbox in File > Options > General, then double-clicking a Word object will open the object with variables displayed as unresolved. You can then preview the variables to show how they will look when the report is generated.
- Open the report that you want to work with.
- In the User Object Summary tab in the work area, select the Word report object you want to preview variables in and click Preview. The report object is opened and checked in with the variables displayed as resolved (that is, how they will look when the report is generated).
The variables are displayed as resolved until the Word object is checked out.