1.8

Table Of Contents
if(record.fields.GENDER === 'M') {
results.attr("content","Media 2");
}
This script changes the media to Media 2 for male customers.
See "Writing your own scripts" on page260 if you are not familiar with how scripts are
written.
5.
Click Apply, open the tab Preview and browse through the records to see if the script
functions as expected.
6.
When you click OK, the script will be added to the Scripts pane.
Rotating the Media in a Print section
The actual orientation of the Media and that of a section to which the Media is applied may not
match.
The Media can therefore be rotated per Print section:
l
On the Resources pane, expand the Print context; right-click the Print section, and click
Sheet configuration.
l
Click one of the options next to Media rotation.
The Media (to be more accurate: the Virtual Stationery images specified for this Media) as well
as the section's background image will be rotated accordingly in the entire section.
Note that any Virtual Stationery settings made for the Media also influence how the Media is
displayed in each section (see "Setting Media properties" on page102).
If in the Media properties, the Virtual Stationery position is set to Absolute, any offset given by
the Top and Left values will be applied after rotation. A Virtual Stationery image located
absolutely at the top left (Top: 0, Left: 0) will still appear at the top left of the page after rotating
the Media.
Printing virtual stationery
Media are not printed, unless you want them to. Printing the virtual stationery is one of the
settings in a Job Creation Preset. To have the virtual stationery printed as part of the Print
output:
Page 106