1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
* Example of how to call PrintOptions.sbs to set Header and Footer:
.
script "c:\\Program Files\\SPSS\\SPSS Script Exchange\\Other\\PrintOptions.sbs"  /
  ("Header=""Your Favorite Header Here"", "+
   "Footer='Footer text here ... Page &[Page]',"+
   "Orientation = landscape, "+
   "StartPage=7 "+
   "NewDocument = True " ) .

* Note: &[Page] is the page number symbol.  
* It will be replaced by the correct number on each page, beginning with StartPage.
.
* More complicated example, note that to include quotes within a quoted string,
*  the quote needs to be doubled: " ""quote"" " to obtain  "quote", or ' ''single'' to obtain  'single' .
.
script "c:\\Program Files\\SPSS\\SPSS Script Exchange\\Other\\PrintOptions.sbs"  /
  ("Header=""Strings can even have ""Footer"" (which is a parameter name) and quotes"", "+
   "Footer='Use single quotes around ""double quotes"" and vice versa [&[Page]]' ") .

* Parameters for PrintOptions script, illustrating all parameters: 
*  but be careful that total characters does not exceed 255.
.
script "c:\\Program Files\\SPSS\\SPSS Script Exchange\\Other\\PrintOptions.sbs"  /
  ("Header="" "", "+
  "Footer='Page [&[Page]]', "+
  "Orientation = landscape , "+
  "StartPage= 17 , "+
  "SpaceBetweenItems = 24, "+
  "ChartSize = AsIs,  "+
  "PaperSize = Letter,  "+
  "PrintRange = All,	 "+
  "PrintDocument = False, "+
  "NewDocument = False "   ) .


* COMPLETE LIST OF Parameters for PrintOptions script.
* Header="Strings can even have 'Footer' (which is a parameter name) and quotes", 
* Footer='Use single quotes around "double quotes" and vice versa [&[Page]]', 
* Orientation = landscape ,	[ Portrait | Landscape ]
* StartPage= 17 ,		[ any number ]
* SpaceBetweenItems = 24,	[ any number ]
* ChartSize = AsIs,		[ AsIs | Full | Half | Quarter ]
* PaperSize = Letter,		[ Letter | Legal ]
* PrintRange = All,		[ All | Selected ]
* PrintDocument = False,	[ True | False ]
* NewDocument = False,	[ True | False ]
.
Related pages

...