
With the function modules PRINT_TEXT and OPEN_FORM, you can set output formatting and print control using the parameter OPTIONS. The data you pass to this parameter must have the structure ITCPO. The fields of this structure come from the areas SAPscript, the spool, and SAPcomm. Some of these fields can be changed by the user on the selection screen, if you requested it using the parameter DIALOG with the above function modules. The print program evaluates these changes using the corresponding fields of the parameter RESULT.
|
TDPAGESLCT |
SAPscript: select print page |
|
TDPREVIEW |
SAPscript: Print Preview |
|
TDNOPREV |
SAPscript: Suppress print preview |
|
TDNOPRINT |
SAPscript: disable printing from within print view |
|
TDTITLE |
SAPscript: text for tiltle line in the output selection screen |
|
TDPROGRAM |
SAPscript: program name for replacing symbols |
|
TDTEST |
SAPscript: test printout |
|
TDIEXIT |
SAPscript: return immediately after printing |
|
TDGETOTF |
SAPscript: return OTF table, no print output |
|
TDSCRNPOS |
SAPscript: display position of OTF on screen |
|
TDDEST |
Spool: name of the output device |
|
TDPRINTE |
Spool: name of the device type |
|
TDCOPIES |
Spool: Number of copies |
|
TDNEWID |
Spool: new request |
|
TDIMMED |
Spool: print request immediately |
|
TDDELETE |
Spool: delete request after printing |
|
TDLIFETIME |
Spool: retention time of the request |
|
TDDATASET |
Spool: identification of the request |
|
TDSUFFIX1 |
Spool: suffix 1 of the request |
|
TDSUFFIX2 |
Spool: suffix 2 of the request |
|
TDAUTORITY |
Spool: authorization for a request |
|
TDARMOD |
Spool: Archiving mode |
|
TDCOVER |
Spool: print cover page |
|
TDCOVTITLE |
Spool: Cover page: Title text |
|
TDRECEIVER |
Spool: Cover page: recipient name |
|
TDDIVISION |
Spool: Cover page: division name |
|
TDSCHEDULE |
SAPcomm: type of scheduled send time |
|
TDSENDDATE |
SAPcomm: requested send date |
|
TDSENDTIME |
SAPcomm: requested send time |
|
TDTELELAND |
SAPcomm: country key of recipient country |
|
TDTELENUM |
SAPcomm: telecommunications partner |
TDPAGESLCT: SAPscript: Page Selection
The field contains the page specifications of the pages to be printed. Single pages, page ranges or combinations can be specified. If the field is empty, the system prints all pages.
The page numbers refer to the physical pages of the SAPscript printout, not to the logical page numbering of the form.
Example:
|
4 |
only page 4 |
|
2-5 |
pages 2 to 5, included |
|
20 |
from beginning to page 20, included |
|
3- |
from page 3 to end |
To combine these variants, separate the different specifications with commas:
4,8-10,15-
prints pages 4, 8 to 10 and then from page 15 to the end of the output.
The user can change the values proposed in this field on the selection screen.
TDPREVIEW: SAPscript: Print Preview
The field determines whether SAPscript shall create a print view. You can then see on the screen exactly what the printout will look like later. In background processing, the system does not interpret this field. It always creates a spool request.
Possible values:
|
'X' |
print view wanted |
|
' ' |
no print view wanted |
TDNOPREV: SAPscript: Suppress print preview
On the print selection screen, the user can choose to display the print view of the SAPscript output on the screen. If you want to disable this function, use field TDNOPREV.
Possible values:
|
'X' |
disable print view function |
|
' ' |
allow print view function |
TDNOPRINT: SAPscript: No print from print preview
The switch serves to control whether the displayed text can be printed from the print preview of a SAPscript document. This parameter is set if, for example, the application program wants to control the execution of the print output independently of the user's specifications.
Possible values:
|
'X' |
printing from within print view disabled |
|
' ' |
Printing from within print view allowed |
TDTITLE: SAPscript: text for title line of print selection screen
TDTITLE: SAPscript: text for title line of print selection screenThe text in this field is displayed in the title line of the print selection screen.
TDPROGRAM: SAPscript: program name for replacing symbols
TDPROGRAM: SAPscript: program name for replacing symbolsIn order to replace program symbols, SAPscript has to know in which active program the work areas for those values that are to be adopted lie. If nothing is specified it will look for fields in the program first called up (main program from SY-CPROG), otherwise in the data area of the program specified here.
The program name is valid during the entire print process. With form printing, however, you can specify a new program name when calling the function module START_FORM. This new program name is then valid until the next END_FORM. Afterwards, the system uses the program name specified in TDPROGRAM again.
SAPscript accesses the table fields of this program using a dynamic ASSIGN with the program name specified here. If no program name is entered or if the program has not been loaded yet, the system treats the symbol as text symbol.
TDTEST: SAPscript: test printout
TDTEST: SAPscript: test printoutUse this field to format a text for printing in a test mode. This means that the system does not replace the symbols in the text with their current values. Instead, it represents all output positions of a symbol value using 'X'.
Possible values:
|
'X' |
format text in test mode |
|
' ' |
format text as usual |
TDIEXIT: SAPscript: return immediately after printing
TDIEXIT: SAPscript: return immediately after printingThis parameter allows you to determine whether the system branches straight back to the application program from the print preview after printing. Normally after printing you remain in the print preview.
It can be necesary to branch back to the application program if, for example, you wish to ensure that the text can only be printed once or if the print preview is no longer needed after printing.
Possible values:
|
'X' |
leave print view immediately after printing |
|
' ' |
remain in print view after printing |
TDGETOTF: SAPscript: return the OTF table
TDGETOTF: SAPscript: return the OTF tableIf you enter 'X' in this field, the SAPscript composer produces the print format as usual, but does not pass it to the spool or print view. Instead, it passes the OTF format created to the calling program for further processing, using the table parameter OTFDATA of the function modules PRINT_TEXT and CLOSE_FORM.
Possible values:
|
'X' |
return output format |
|
' ' |
pass output format to spool or print view |
TDDEST: Spool: name of the output device
TDDEST: Spool: name of the output deviceSpecify the name of the device on which you want to output the formatted SAPscript text. If you enter '*' or leave the field empty, the system uses the default value specific in the user master record of the active user. If, in this case, no printer is specified in the user master record, the system displays the print selection screen, even if you wanted to suppress the dialog when calling the function modules PRINT_TEXT or OPEN_FORM (parameter DIALOG).
The user can change the values proposed in this field on the selection screen.
TDPRINTER: Spool: name of the device type
TDPRINTER: Spool: name of the device typeUsually, this field is empty. On the selection screen, the user can choose among all existing printers. However, if you want to ensure that the text is output on printers of a certain type only, you can specify the device type in this field. On the selection screen, the system then offers only the printers of this type.
The device type you specify must be defined in table TSP0A. To find these types out, use the spool administration (transaction SPAD).
TDCOPIES: Spool: number of copies
TDCOPIES: Spool: number of copiesSpecify how often you want the spool to print a text. '1' means that the entire text is printed once (default). If you specify '2', the system prints all pages twice. SAPscript internally replaces the value '0' with '1'.
When you create more than one copy, the sequence of the printed pages is 1-2-3..., 1-2-3...
The user can change the values proposed in this field on the selection screen.
TDNEWID: Spool: new spool request
TDNEWID: Spool: new spool requestThis field determines whether to append the current spool request to an existing request with the same attributes or whether to create a new request. To append a request to another, the values of the fields Name, Output device, Number of Copies and the Formatting Mode must be the same, and the existing spool request must still be active. This is no longer the case, if a spool request is released to printing. If the system does not find a matching spool request, it always creates a new one.
Possible values:
|
'X' |
create a new spool request |
|
' ' |
find a matching spool request for appending |
The user can change the values proposed in this field on the selection screen.
TDIMMED: Spool: print request immediately
TDIMMED: Spool: print request immediatelyUse this field to determine whether to send the print request to the output device immediately after completing it. Otherwise, you must use the spool print control (transaction SP01) to release the print request.
Possible values:
|
'X' |
print request immediately after completing it |
|
' ' |
keep request in spool after completing it |
The user can change the values proposed in this field on the selection screen.
TDDELETE: Spool: delete request after printing
TDDELETE: Spool: delete request after printingUse this field to determine whether to delete the spool request immediately after printing it on the output device or whether to keep it for the spool retention period.
Possible values:
|
'X' |
delete immediately after printing |
|
' ' |
delete after retention time has expired |
The user can change the values proposed in this field on the selection screen.
TDLIFETIME: Spool. retention time of the request
TDLIFETIME: Spool. retention time of the requestThis field determines for how many days the system keeps a request in the spool before deleting it. If the field is empty, SAPscript inserts the default value '8'.
The user can change the values proposed in this field on the selection screen.
TDDATASET: Spool: identification of the request
TDDATASET: Spool: identification of the requestThe field is the first component of the three-part identification of the spool request (including also the fields TDSUFFIX1 and TDSUFFIX2). There is no naming convention for the identification. If your application uses a certain convention, see the corresponding application documentation.
If the field is empty, SAPscript enters the value SCRIPT. The user can change the values proposed in this field on the selection screen.
TDSUFFIX1: Spool: suffix 1 of the request
TDSUFFIX1: Spool: suffix 1 of the requestSecond part of the identification of the spool request. See also the description of field TDDATASET.
If the field is empty, SAPscript enters the output destination (TDDEST).
The user can change the values proposed in this field on the selection screen.
TDSUFFIX2: Spool: suffix 2 of the request
TDSUFFIX2: Spool: suffix 2 of the requestThird part of the identification of the spool request. See also the description of field TDDATASET.
If the field is empty, SAPscript enters the name of the user.
The user can change the values proposed in this field on the selection screen.
TDAUTORITY: Spool: authorization for request
TDAUTORITY: Spool: authorization for requestThis field defines an authorization value for the spool request. Only users with the specified authorization can display or print the contents of the spool request.
The spool print control (transaction SP01) checks whether the authorization object S_SPO_ACT (spool actions) of the user contains the specified value.
The user can change the values proposed in this field on the selection screen.
TDARMOD: Spool: archiving mode
TDARMOD: Spool: archiving modeUse this field to determine whether only to print a request or whether to store it in the optical archive as well.
Possible values:
|
'1' |
only print request (default) |
|
'2' |
only archive request |
|
'3' |
print and archive request |
The user can change the values proposed in this field on the selection screen.
TDCOVER: Spool: print cover page
TDCOVER: Spool: print cover pageThis field determines whether the printout includes a cover page containing information such as recipient name, division name, format used, and so on.
Possible values:
|
'X' |
print cover page |
|
' ' |
Suppress cover page |
|
'D' |
print cover page depending on the setting of the respective output device. (see definition of the device in the spool administration (transaction SPAD), in the column output devices) |
The user can change the values proposed in this field on the selection screen.
TDCOVTITLE: Spool: Cover page: title text
TDCOVTITLE: Spool: Cover page: title textThis field contains a text describing the spool request. It appears on the cover page.
The user can change the values proposed in this field on the selection screen.
TDRECEIVER: Spool: Cover page: recipient name
TDRECEIVER: Spool: Cover page: recipient nameYou can specify the name of the user who receives the spool request. The system prints this name on the cover page. The default value is the name of the current user.
The user can change the values proposed in this field on the selection screen.
TDDIVISION: Spool: Cover page: division name
TDDIVISION: Spool: Cover page: division nameThis field contains the name of the division to which the user belongs. The system prints this name on the cover page.
The user can change the values proposed in this field on the selection screen.
TDSCHEDULE: SAPcomm: type of scheduled send time
TDSCHEDULE: SAPcomm: type of scheduled send timeUse this field to determine whether to send a spool request via the SAP communication interface immediately or whether to wait for the night.
Possible values:
|
'IMM' |
send request immediately |
|
'NIG' |
send request during the night |
If the field is empty, the system uses the default value 'IMM'.
The user can change the values proposed in this field on the selection screen.
TDSENDDATE: SAPcomm: requested send date
TDSENDDATE: SAPcomm: requested send dateIn this field, enter the date on which to send the print request via the SAP communication interface.
The user can change the values proposed in this field on the selection screen.
TDSENDTIME: SAPcomm: requested send time
TDSENDTIME: SAPcomm: requested send timeIn this field, enter the time at which to send the print request via the SAP communication interface.
The user can change the values proposed in this field on the selection screen.
TDTELELAND: SAPcomm: country key for recipient country
TDTELELAND: SAPcomm: country key for recipient countryAccording to the country key specified in this field, the SAP communication interface determines the country-specific area code and uses it as prefix to the telephone number of the telecommunications partner specified in field TDTELENUM.
The user can change the values proposed in this field on the selection screen.
TDTELENUM: SAPcomm: number of telecommunications partner
TDTELENUM: SAPcomm: number of telecommunications partnerIn this field, enter the number of the desired telecommunications partner is the way it is dialed in the recipient country. The system automatically includes the area code which you specify in the field TDTELELAND.
Alternatively an '&' can be used as the first character to disable number testing and number formatting. In this case, you must specify the entire number, including area code, but without operator call.
The telephone number must be of a certain format:
TELEFAX
Allows only digits and the characters ' ( ', ' ) ', ' / ', ' - ', and ' . ' as well as blanks.
TELEX
Allows only digits, the letters A to Z, and blanks. The number must have the following structure:
nnn...n aaaa..a ccc
'n' are digits that form the numeric part of the telex identification
'a' letters that for the alphanumeric part of the telex identification 'ccc' consists of one, two, or three letters and corresponds to the country key
TELETEX
Only numbers and the letters A to Z. The number must be made up as follows:
nnn...n=aaaa..a
'n' are digits that form the numeric part of the teletex identification. 'a' letters that form the alphanumeric part of the teletex identification
The user can change the proposed value on the print selection screen.