SAP SET_PRINT_PARAMETERS Function Module for Set Spool Print Parameters and Archive Parameters









SET_PRINT_PARAMETERS is a standard set print parameters SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Set Spool Print Parameters and Archive Parameters processing and below is the pattern details for this FM, showing its interface including any import and export parameters, exceptions etc. there is also a full "cut and paste" ABAP pattern code example, along with implementation ABAP coding, documentation and contribution comments specific to this or related objects.


See here to view full function module documentation and code listing for set print parameters FM, simply by entering the name SET_PRINT_PARAMETERS into the relevant SAP transaction such as SE37 or SE38.

Function Group: SPRI
Program Name: SAPLSPRI
Main Program: SAPLSPRI
Appliation area: S
Release date: 22-Apr-1996
Mode(Normal, Remote etc): Normal Function Module
Update:



Function SET_PRINT_PARAMETERS pattern details

In-order to call this FM within your sap programs, simply using the below ABAP pattern details to trigger the function call...or see the full ABAP code listing at the end of this article. You can simply cut and paste this code into your ABAP progrom as it is, including variable declarations.
CALL FUNCTION 'SET_PRINT_PARAMETERS'"Set Spool Print Parameters and Archive Parameters
EXPORTING
* ARCHIVE_ID = C_CHAR_UNKNOWN "Default for archiving ID
* DEPARTMENT = C_CHAR_UNKNOWN "Default for 'department'
* DESTINATION = C_CHAR_UNKNOWN "Default for 'output device'
* EXPIRATION = C_NUM1_UNKNOWN "Default for 'retention period'
* IMMEDIATELY = C_CHAR_UNKNOWN "Default for 'Print immediately'
* IN_ARCHIVE_PARAMETERS = ' ' "List of all archiving parameters
* IN_PARAMETERS = ' ' "List of all default parameters
* LAYOUT = C_CHAR_UNKNOWN "Default for 'format'
* LINE_COUNT = C_INT_UNKNOWN "Default for 'Rows'
* LINE_SIZE = C_INT_UNKNOWN "Default for 'columns'
* LIST_NAME = C_CHAR_UNKNOWN "Default for 'spool request name'
* ARCHIVE_INFO = C_CHAR_UNKNOWN "Additional information for report names
* LIST_TEXT = C_CHAR_UNKNOWN "Default for 'spool request text'
* NEW_LIST_ID = C_CHAR_UNKNOWN "Default for 'New spool request'
* RECEIVER = C_CHAR_UNKNOWN "Default for 'recipient'
* RELEASE = C_CHAR_UNKNOWN "Default for 'retention period'
* SAP_COVER_PAGE = C_CHAR_UNKNOWN "Default for the output of the SAP cover sheet
* HOST_COVER_PAGE = C_CHAR_UNKNOWN "
* PRIORITY = C_NUM1_UNKNOWN "
* SAP_OBJECT = C_CHAR_UNKNOWN "Name of the application for the archiving
* TYPE = C_CHAR_UNKNOWN "Default 'Spool request type'
* FOOT_LINE = C_CHAR_UNKNOWN "Footer line on/off
* ARCHIVE_MODE = C_CHAR_UNKNOWN "Control of the printing and archiving
* ARCHIVE_TEXT = C_CHAR_UNKNOWN "Info text for the archive request
* AR_OBJECT = C_CHAR_UNKNOWN "Archiving object
* AUTHORITY = C_CHAR_UNKNOWN "Default for 'authorization'
* COPIES = C_NUM3_UNKNOWN "Default for 'number of copies'
* COVER_PAGE = C_CHAR_UNKNOWN "Selection cover sheet output value
* DATA_SET = C_CHAR_UNKNOWN "Default for name of the spool data
.



IMPORTING Parameters details for SET_PRINT_PARAMETERS

ARCHIVE_ID - Default for archiving ID

Data type: ARC_PARAMS-ARCHIV_ID
Default: C_CHAR_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

DEPARTMENT - Default for 'department'

Data type: PRI_PARAMS-PRABT
Default: C_CHAR_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

DESTINATION - Default for 'output device'

Data type: PRI_PARAMS-PDEST
Default: C_CHAR_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

EXPIRATION - Default for 'retention period'

Data type: PRI_PARAMS-PEXPI
Default: C_NUM1_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

IMMEDIATELY - Default for 'Print immediately'

Data type: PRI_PARAMS-PRIMM
Default: C_CHAR_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

IN_ARCHIVE_PARAMETERS - List of all archiving parameters

Data type: ARC_PARAMS
Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)

IN_PARAMETERS - List of all default parameters

Data type: PRI_PARAMS
Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)

LAYOUT - Default for 'format'

Data type: PRI_PARAMS-PAART
Default: C_CHAR_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

LINE_COUNT - Default for 'Rows'

Data type: PRI_PARAMS-LINCT
Default: C_INT_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

LINE_SIZE - Default for 'columns'

Data type: PRI_PARAMS-LINSZ
Default: C_INT_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

LIST_NAME - Default for 'spool request name'

Data type: PRI_PARAMS-PLIST
Default: C_CHAR_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

ARCHIVE_INFO - Additional information for report names

Data type: ARC_PARAMS-INFO
Default: C_CHAR_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

LIST_TEXT - Default for 'spool request text'

Data type: PRI_PARAMS-PRTXT
Default: C_CHAR_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

NEW_LIST_ID - Default for 'New spool request'

Data type: PRI_PARAMS-PRNEW
Default: C_CHAR_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

RECEIVER - Default for 'recipient'

Data type: PRI_PARAMS-PRREC
Default: C_CHAR_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

RELEASE - Default for 'retention period'

Data type: PRI_PARAMS-PRREL
Default: C_CHAR_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

SAP_COVER_PAGE - Default for the output of the SAP cover sheet

Data type: PRI_PARAMS-PRSAP
Default: C_CHAR_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

HOST_COVER_PAGE -

Data type: PRI_PARAMS-PRUNX
Default: C_CHAR_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

PRIORITY -

Data type: PRI_PARAMS-PRIOT
Default: C_NUM1_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

SAP_OBJECT - Name of the application for the archiving

Data type: ARC_PARAMS-SAP_OBJECT
Default: C_CHAR_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

TYPE - Default 'Spool request type'

Data type: PRI_PARAMS-PTYPE
Default: C_CHAR_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

FOOT_LINE - Footer line on/off

Data type: PRI_PARAMS-FOOTL
Default: C_CHAR_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

ARCHIVE_MODE - Control of the printing and archiving

Data type: PRI_PARAMS-ARMOD
Default: C_CHAR_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

ARCHIVE_TEXT - Info text for the archive request

Data type: ARC_PARAMS-ARCTEXT
Default: C_CHAR_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

AR_OBJECT - Archiving object

Data type: ARC_PARAMS-AR_OBJECT
Default: C_CHAR_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

AUTHORITY - Default for 'authorization'

Data type: PRI_PARAMS-PRBER
Default: C_CHAR_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

COPIES - Default for 'number of copies'

Data type: PRI_PARAMS-PRCOP
Default: C_NUM3_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

COVER_PAGE - Selection cover sheet output value

Data type: PRI_PARAMS-PRBIG
Default: C_CHAR_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

DATA_SET - Default for name of the spool data

Data type: PRI_PARAMS-PRDSN
Default: C_CHAR_UNKNOWN
Optional: Yes
Call by Reference: No ( called with pass by value option)

Copy and paste ABAP code example for SET_PRINT_PARAMETERS Function Module

The ABAP code below is a full code listing to execute function module POPUP_TO_CONFIRM including all data declarations. The code uses the original data declarations rather than the latest in-line data DECLARATION SYNTAX but I have included an ABAP code snippet at the end to show how declarations would look using the newer method of declaring data variables on the fly. This will allow you to compare and fully understand the new inline method. Please note some of the newer syntax such as the @DATA is not available until a later 4.70 service pack (SP8), which i why i have stuck to the origianl for this example.

DATA:
lv_archive_id  TYPE ARC_PARAMS-ARCHIV_ID, "   C_CHAR_UNKNOWN
lv_department  TYPE PRI_PARAMS-PRABT, "   C_CHAR_UNKNOWN
lv_destination  TYPE PRI_PARAMS-PDEST, "   C_CHAR_UNKNOWN
lv_expiration  TYPE PRI_PARAMS-PEXPI, "   C_NUM1_UNKNOWN
lv_immediately  TYPE PRI_PARAMS-PRIMM, "   C_CHAR_UNKNOWN
lv_in_archive_parameters  TYPE ARC_PARAMS, "   SPACE
lv_in_parameters  TYPE PRI_PARAMS, "   SPACE
lv_layout  TYPE PRI_PARAMS-PAART, "   C_CHAR_UNKNOWN
lv_line_count  TYPE PRI_PARAMS-LINCT, "   C_INT_UNKNOWN
lv_line_size  TYPE PRI_PARAMS-LINSZ, "   C_INT_UNKNOWN
lv_list_name  TYPE PRI_PARAMS-PLIST, "   C_CHAR_UNKNOWN
lv_archive_info  TYPE ARC_PARAMS-INFO, "   C_CHAR_UNKNOWN
lv_list_text  TYPE PRI_PARAMS-PRTXT, "   C_CHAR_UNKNOWN
lv_new_list_id  TYPE PRI_PARAMS-PRNEW, "   C_CHAR_UNKNOWN
lv_receiver  TYPE PRI_PARAMS-PRREC, "   C_CHAR_UNKNOWN
lv_release  TYPE PRI_PARAMS-PRREL, "   C_CHAR_UNKNOWN
lv_sap_cover_page  TYPE PRI_PARAMS-PRSAP, "   C_CHAR_UNKNOWN
lv_host_cover_page  TYPE PRI_PARAMS-PRUNX, "   C_CHAR_UNKNOWN
lv_priority  TYPE PRI_PARAMS-PRIOT, "   C_NUM1_UNKNOWN
lv_sap_object  TYPE ARC_PARAMS-SAP_OBJECT, "   C_CHAR_UNKNOWN
lv_type  TYPE PRI_PARAMS-PTYPE, "   C_CHAR_UNKNOWN
lv_foot_line  TYPE PRI_PARAMS-FOOTL, "   C_CHAR_UNKNOWN
lv_archive_mode  TYPE PRI_PARAMS-ARMOD, "   C_CHAR_UNKNOWN
lv_archive_text  TYPE ARC_PARAMS-ARCTEXT, "   C_CHAR_UNKNOWN
lv_ar_object  TYPE ARC_PARAMS-AR_OBJECT, "   C_CHAR_UNKNOWN
lv_authority  TYPE PRI_PARAMS-PRBER, "   C_CHAR_UNKNOWN
lv_copies  TYPE PRI_PARAMS-PRCOP, "   C_NUM3_UNKNOWN
lv_cover_page  TYPE PRI_PARAMS-PRBIG, "   C_CHAR_UNKNOWN
lv_data_set  TYPE PRI_PARAMS-PRDSN. "   C_CHAR_UNKNOWN

  CALL FUNCTION 'SET_PRINT_PARAMETERS'  "Set Spool Print Parameters and Archive Parameters
    EXPORTING
         ARCHIVE_ID = lv_archive_id
         DEPARTMENT = lv_department
         DESTINATION = lv_destination
         EXPIRATION = lv_expiration
         IMMEDIATELY = lv_immediately
         IN_ARCHIVE_PARAMETERS = lv_in_archive_parameters
         IN_PARAMETERS = lv_in_parameters
         LAYOUT = lv_layout
         LINE_COUNT = lv_line_count
         LINE_SIZE = lv_line_size
         LIST_NAME = lv_list_name
         ARCHIVE_INFO = lv_archive_info
         LIST_TEXT = lv_list_text
         NEW_LIST_ID = lv_new_list_id
         RECEIVER = lv_receiver
         RELEASE = lv_release
         SAP_COVER_PAGE = lv_sap_cover_page
         HOST_COVER_PAGE = lv_host_cover_page
         PRIORITY = lv_priority
         SAP_OBJECT = lv_sap_object
         TYPE = lv_type
         FOOT_LINE = lv_foot_line
         ARCHIVE_MODE = lv_archive_mode
         ARCHIVE_TEXT = lv_archive_text
         AR_OBJECT = lv_ar_object
         AUTHORITY = lv_authority
         COPIES = lv_copies
         COVER_PAGE = lv_cover_page
         DATA_SET = lv_data_set
. " SET_PRINT_PARAMETERS




ABAP code using 7.40 inline data declarations to call FM SET_PRINT_PARAMETERS

The below ABAP code uses the newer in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. Please note some of the newer syntax below, such as the @DATA is not available until 4.70 EHP 8.

"SELECT single ARCHIV_ID FROM ARC_PARAMS INTO @DATA(ld_archive_id).
DATA(ld_archive_id) = C_CHAR_UNKNOWN.
 
"SELECT single PRABT FROM PRI_PARAMS INTO @DATA(ld_department).
DATA(ld_department) = C_CHAR_UNKNOWN.
 
"SELECT single PDEST FROM PRI_PARAMS INTO @DATA(ld_destination).
DATA(ld_destination) = C_CHAR_UNKNOWN.
 
"SELECT single PEXPI FROM PRI_PARAMS INTO @DATA(ld_expiration).
DATA(ld_expiration) = C_NUM1_UNKNOWN.
 
"SELECT single PRIMM FROM PRI_PARAMS INTO @DATA(ld_immediately).
DATA(ld_immediately) = C_CHAR_UNKNOWN.
 
DATA(ld_in_archive_parameters) = ' '.
 
DATA(ld_in_parameters) = ' '.
 
"SELECT single PAART FROM PRI_PARAMS INTO @DATA(ld_layout).
DATA(ld_layout) = C_CHAR_UNKNOWN.
 
"SELECT single LINCT FROM PRI_PARAMS INTO @DATA(ld_line_count).
DATA(ld_line_count) = C_INT_UNKNOWN.
 
"SELECT single LINSZ FROM PRI_PARAMS INTO @DATA(ld_line_size).
DATA(ld_line_size) = C_INT_UNKNOWN.
 
"SELECT single PLIST FROM PRI_PARAMS INTO @DATA(ld_list_name).
DATA(ld_list_name) = C_CHAR_UNKNOWN.
 
"SELECT single INFO FROM ARC_PARAMS INTO @DATA(ld_archive_info).
DATA(ld_archive_info) = C_CHAR_UNKNOWN.
 
"SELECT single PRTXT FROM PRI_PARAMS INTO @DATA(ld_list_text).
DATA(ld_list_text) = C_CHAR_UNKNOWN.
 
"SELECT single PRNEW FROM PRI_PARAMS INTO @DATA(ld_new_list_id).
DATA(ld_new_list_id) = C_CHAR_UNKNOWN.
 
"SELECT single PRREC FROM PRI_PARAMS INTO @DATA(ld_receiver).
DATA(ld_receiver) = C_CHAR_UNKNOWN.
 
"SELECT single PRREL FROM PRI_PARAMS INTO @DATA(ld_release).
DATA(ld_release) = C_CHAR_UNKNOWN.
 
"SELECT single PRSAP FROM PRI_PARAMS INTO @DATA(ld_sap_cover_page).
DATA(ld_sap_cover_page) = C_CHAR_UNKNOWN.
 
"SELECT single PRUNX FROM PRI_PARAMS INTO @DATA(ld_host_cover_page).
DATA(ld_host_cover_page) = C_CHAR_UNKNOWN.
 
"SELECT single PRIOT FROM PRI_PARAMS INTO @DATA(ld_priority).
DATA(ld_priority) = C_NUM1_UNKNOWN.
 
"SELECT single SAP_OBJECT FROM ARC_PARAMS INTO @DATA(ld_sap_object).
DATA(ld_sap_object) = C_CHAR_UNKNOWN.
 
"SELECT single PTYPE FROM PRI_PARAMS INTO @DATA(ld_type).
DATA(ld_type) = C_CHAR_UNKNOWN.
 
"SELECT single FOOTL FROM PRI_PARAMS INTO @DATA(ld_foot_line).
DATA(ld_foot_line) = C_CHAR_UNKNOWN.
 
"SELECT single ARMOD FROM PRI_PARAMS INTO @DATA(ld_archive_mode).
DATA(ld_archive_mode) = C_CHAR_UNKNOWN.
 
"SELECT single ARCTEXT FROM ARC_PARAMS INTO @DATA(ld_archive_text).
DATA(ld_archive_text) = C_CHAR_UNKNOWN.
 
"SELECT single AR_OBJECT FROM ARC_PARAMS INTO @DATA(ld_ar_object).
DATA(ld_ar_object) = C_CHAR_UNKNOWN.
 
"SELECT single PRBER FROM PRI_PARAMS INTO @DATA(ld_authority).
DATA(ld_authority) = C_CHAR_UNKNOWN.
 
"SELECT single PRCOP FROM PRI_PARAMS INTO @DATA(ld_copies).
DATA(ld_copies) = C_NUM3_UNKNOWN.
 
"SELECT single PRBIG FROM PRI_PARAMS INTO @DATA(ld_cover_page).
DATA(ld_cover_page) = C_CHAR_UNKNOWN.
 
"SELECT single PRDSN FROM PRI_PARAMS INTO @DATA(ld_data_set).
DATA(ld_data_set) = C_CHAR_UNKNOWN.
 


Search for further information about these or an SAP related objects



Comments on this SAP object

What made you want to lookup this SAP object? Please tell us what you were looking for and anything you would like to be included on this page!