R3_ACTIVATE_REPORT
Use the R3_ACTIVATE_REPORT script element to modify an ABAP step in an SAP job. You can reset the report name, the variant, and various archiving and printing parameters of the step.
Tips:
-
Enable the Combine Job Steps option in the Connection object to combine several R3_ACTIVATE_REPORT script elements into one job. For more information, see Defining R3 Connections: Interfaces Section.
-
Instead of using a variant, you can assign selection criteria using a script. For more information, see R3_SET_SELECT_OPTION.
Transaction: SM36, SM37
Interface: AE and Standard
Syntax
R3_ACTIVATE_REP[ORT] REPORT=...[,VARIANT=...][,DESTINATION=...][,COPIES=...][,LIST_NAME=...][,LIST_TEXT=...][,IMMEDIATELY=...][,RELEASE=...][,NEW_LIST_ID=...][,EXPIRATION=...][,LINE_COUNT=...][,LINE_SIZE=...][,LAYOUT=...][,COVERPAGE=...][,SAP_COVER_PAGE=...][,OS_COVER_PAGE=...][,RECEIVER=...][,DEPARTMENT=...][,AUTHORITY=...][,DATA_SET=...][,TYPE=...][,SPOOL_PRIORITY=...][,TEXTONLY=...][,FRAMES=...][,SUPPRESS_SHADING=...][,WITH_STRUCTURE=...][,DEFAULT_SPOOL_SIZE=...][,PRINTER_MAIL_ADDRESS=...][,SPOOL_PAGE_FROM=...][,SPOOL_PAGE_TO=...][,ARCHIVE_MODE=...][,ARCHIVE_SAPOBJECT=...][,ARCHIVE_OBJECT=...][,ARCHIVE_INFO=...][,ARCHIVE_TEXT=...][,MONITOR=...][,WAIT=...][,ABORTED=...][,REPLICATE=...][,BEG_LOGLINES=...][,END_LOGLINES=...][,GET_SPOOL=...]
Parameters
| Parameter | Description | Format |
|---|---|---|
| REP[ORT]= | Name of the report | Script literal |
| VAR[IANT]=
(Optional) |
Name of the variant | Script literal |
Print Parameters
| Parameter | Description | Format | Allowed Values | Default Value |
|---|---|---|---|---|
| DEST[INATION]=
(Optional) |
Name of the output device, typically a printer, fax machine, or similar device. Important! For technical reasons caused by the SAP XBP interface, long SAP printer names are not supported. Use the 4-digit technical name instead. |
Script literal | n.a. | n.a. |
| COPIES=
(Optional) |
Number of copies to print | Integer | n.a. | 0 |
| LIST_N[AME]=
(Optional) |
Name of the spool request. Can contain any letters, numbers, special characters, and blanks. |
Script literal | n.a. | First 8 characters of the report name, an underscore (_), and the first 3 characters of the user name |
| LIST_T[EXT]=
(Optional) |
Descriptive text for the cover page of the spool request. Can contain any letters, numbers, special characters, and blanks. |
Script literal | n.a. | n.a. |
| IMM[EDIATELY]=
(Optional) |
Controls whether the spool request is printed immediately | Script literal |
|
NO |
| REL[EASE]=
(Optional) |
Controls whether the spool request is deleted immediately after printing, or only when the spool retention period expires | Script literal |
|
NO |
| NEW_LIST_ID=
(Optional) |
Controls whether a new spool request is created | Script literal |
|
YES |
| EXPIR[ATION]=
(Optional) |
Number of days a spool request is retained before being deleted | Integer | n.a. | 0 |
| LINE_COUNT=
(Optional) |
Number of lines per list page. In non-print format: a value of 0 or empty means the number of pages is not limited. In print format: the maximum number of lines depends on the selected layout format. |
Integer | n.a. | 0 |
| LINE_SIZE=
(Optional) |
Line width of the list. In print format: the maximum line width depends on the selected layout format. |
Integer | n.a. | 0 |
| LAYOUT=
(Optional) |
Output format of the spool request. Defines the page format, including the maximum number of lines and columns on a printed page. |
Script literal | n.a. | n.a. |
| COVER[PAGE]=
(Optional) |
Controls whether a cover page with report selections is printed. When enabled, the cover page documents the parameters used for the execution. |
Script literal |
|
NO |
| SAP_COVER[_PAGE]=
(Optional) |
SAP cover page setting | Script literal |
|
"" |
| OS_COVER[_PAGE]=
(Optional) |
Host spool cover page setting | Script literal |
|
"" |
| RECEIVER=
(Optional) |
Name of the spool request recipient, printed on the cover page | Script literal | n.a. | Current user name |
| DEPART[MENT]=
(Optional) |
Department name printed on the cover page of the spool request | Script literal | n.a. | n.a. |
| AUTHORITY=
(Optional) |
Authorization for the spool request. Only authorized users can view the spool content. Maximum 12 characters. |
Script literal | n.a. | n.a. |
| DATA_SET=
(Optional) |
Name of the spool dataset | Script literal | n.a. | n.a. |
| TYPE=
(Optional) |
Type of spool request | Script literal | n.a. | n.a. |
| SPOOL_PRI[ORITY]=
(Optional) |
Spool request priority | Integer | n.a. | 5 |
| TEXTO[NLY]=
(Optional) |
Controls the output of non-ASCII characters in a print list | Script literal |
|
NO |
| FRAMES=
(Optional) |
Controls whether frame characters are used in the output | Script literal |
|
YES |
| SUPPRESS_SHADING=
(Optional) |
Controls whether colors and shading are included in the output | Script literal |
|
NO |
| WITH_STRUCTURE=
(Optional) |
Controls whether structured information is included in the report | Script literal |
|
NO |
| DEFAULT_SPOOL_SIZE=
(Optional) |
Controls whether the spool request line width is limited to 255 characters | Script literal |
|
NO |
| PRINTER_MAIL_ADDRESS=
(Optional) |
Email address of an email printer | Script literal | n.a. | n.a. |
| SPOOL_PAGE_FROM=
SPOOL_PAGE_TO= (Optional) |
First and last page to print | String | n.a. | All pages are printed |
Archive Parameters
| Parameter | Description | Format | Allowed Values | Default Value |
|---|---|---|---|---|
| ARCHIVE_M[ODE]=
(Optional) |
Archiving mode for the document | Script literal |
|
1 |
| ARCHIVE_S[APOBJECT]=
(Optional) |
Object type of the business object. Archived objects are classified by object type. | Script literal | n.a. | n.a. |
| ARCHIVE_I[NFO]=
(Optional) |
Information code for the archiving request | Script literal | n.a. | n.a. |
| ARCHIVE_T[EXT]=
(Optional) |
Descriptive text for the archiving request. Can contain any letters, numbers, special characters, and blanks. |
Script literal | n.a. | n.a. |
Control Parameters
| Parameter | Description | Format | Allowed Values | Default Value |
|---|---|---|---|---|
| MON[ITOR]=
(Optional) |
Controls whether status monitoring is logged in the activation report | Script literal |
|
NO |
| WAIT=
(Optional) |
Controls whether the script waits for SAP job child processes to end | Script literal or AE name |
|
NO |
| ABORTED=
(Optional) |
Reaction when a SAP job child process ends abnormally | Script literal or AE name |
|
YES |
| REPL[ICATE]=
(Optional) |
Controls replication of child processes of intercepted jobs in the AE system | Script literal |
|
NO |
| BEG_LOGLINES=
(Optional) |
Number of lines to transfer from the beginning of the SAP job log to the AE job report. Note: If neither BEG_LOGLINES= nor END_LOGLINES= is specified, the complete job log is transferred. If only one is specified, that value is applied. Specifying 0 for both parameters transfers no job log. |
Number | n.a. | n.a. |
| END_LOGLINES=
(Optional) |
Number of lines to transfer from the end of the SAP job log to the AE job report. Note: If neither BEG_LOGLINES= nor END_LOGLINES= is specified, the complete job log is transferred. If only one is specified, that value is applied. Specifying 0 for both parameters transfers no job log. |
Number | n.a. | n.a. |
| GET_SPOOL=
(Optional) |
Controls whether the spool list of the started job is requested or not. When NO: The spool list is not requested. Exception: If you run multiple reports in one job AND you use the Combine job steps option (see Connection (CONN)), the system treats them as a package deal. If even one report has GET_SPOOL set to YES, the spool list will be requested for all of them. Note: Child spool entries are only requested if REPLICATE= is set to YES or ALL. When YES: The spool list is requested and stored as <SAP job count>_<step number>_<spool number>.txt in the directory defined by the Download_dir= parameter in the [GLOBAL] section of the SAP Agent's INI file, see Agent SAP. This text file is also registered as a job output in the AE job, see Registered Job Output |
Script literal |
|
NO |
Examples
The following example activates an ABAP report with a specific variant, cover page, output device, and immediate printing.
R3_ACTIVATE_REPORT REPORT='ZSUSER00',VARIANT='ALL_USERS',COVERPAGE='YES',DESTINATION='LT77',IMMEDIATELY='YES'
See also: