SAP ARCHIVOBJECT_DISPLAY_SAMPLE Function Module for Displaying FAX Documents from an External Storage System
ARCHIVOBJECT_DISPLAY_SAMPLE is a standard archivobject display sample SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Displaying FAX Documents from an External Storage System 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 archivobject display sample FM, simply by entering the name ARCHIVOBJECT_DISPLAY_SAMPLE into the relevant SAP transaction such as SE37 or SE38.
Function Group: OPTY
Program Name: SAPLOPTY
Main Program:
Appliation area:
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function ARCHIVOBJECT_DISPLAY_SAMPLE 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 'ARCHIVOBJECT_DISPLAY_SAMPLE'"Displaying FAX Documents from an External Storage System.
EXPORTING
ARCHIV_DOC_ID = "Identification of the Document to Be Displayed
* WINDOW_TITLE = ' ' "Window title
* DOC_TYPE = ' ' "Document Class
* POSITIONINALFFILE = ' ' "Position
* NOGET = ' ' "
* PATHOFFILE = ' ' "
* EOF = ' ' "
* DALENGTH = ' ' "
* PFSTATUS = ' ' "
* REPORT = ' ' "
* ARCHIV_DOC_INDEX = ' ' "(no longer used)
ARCHIV_ID = "Identification of the Storage System
* OBJECTTYPE = ' ' "
* OBJECT_ID = ' ' "
* AR_OBJECT = ' ' "
* LANGUAGE = ' ' "Logon Language
* SIGN = ' ' "ReferenceFlag
* WINDOW_ID = ' ' "UNique Window Identification
IMPORTING
GOON = "SAP ArchiveLink: Status (X = active, otherwise inactive)
RETURNCODE = "Confirmation
EXCEPTIONS
ERROR_ARCHIV = 1 ERROR_COMMUNICATIONTABLE = 2 ERROR_KERNEL = 3
IMPORTING Parameters details for ARCHIVOBJECT_DISPLAY_SAMPLE
ARCHIV_DOC_ID - Identification of the Document to Be Displayed
Data type: SAPB-SAPADOKIDOptional: No
Call by Reference: No ( called with pass by value option)
WINDOW_TITLE - Window title
Data type: SAPB-SAPWINTITLDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
DOC_TYPE - Document Class
Data type: TOAOM-DOC_TYPEDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
POSITIONINALFFILE - Position
Data type:Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
NOGET -
Data type:Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
PATHOFFILE -
Data type:Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
EOF -
Data type:Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
DALENGTH -
Data type: TOADL-DATALENGTHDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
PFSTATUS -
Data type: SY-PFKEYDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
REPORT -
Data type: RS38M-PROGRAMMDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
ARCHIV_DOC_INDEX - (no longer used)
Data type: SAPB-SAPADOKIDDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
ARCHIV_ID - Identification of the Storage System
Data type: TOAAR-ARCHIV_IDOptional: No
Call by Reference: No ( called with pass by value option)
OBJECTTYPE -
Data type: TOAV0-SAP_OBJECTDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
OBJECT_ID -
Data type: TOAV0-OBJECT_IDDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
AR_OBJECT -
Data type: TOAV0-AR_OBJECTDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
LANGUAGE - Logon Language
Data type:Default: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
SIGN - ReferenceFlag
Data type: SAPB-SAPBZZDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
WINDOW_ID - UNique Window Identification
Data type: SAPB-SAPWINIDDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for ARCHIVOBJECT_DISPLAY_SAMPLE
GOON - SAP ArchiveLink: Status (X = active, otherwise inactive)
Data type: TOAOM-AR_STATUSOptional: No
Call by Reference: No ( called with pass by value option)
RETURNCODE - Confirmation
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
EXCEPTIONS details
ERROR_ARCHIV - Error from Archive System
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
ERROR_COMMUNICATIONTABLE - Inconsistencies in the Archive Table
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
ERROR_KERNEL - Error from SAP Kernel
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for ARCHIVOBJECT_DISPLAY_SAMPLE 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_goon | TYPE TOAOM-AR_STATUS, " | |||
| lv_error_archiv | TYPE TOAOM, " | |||
| lv_archiv_doc_id | TYPE SAPB-SAPADOKID, " | |||
| lv_window_title | TYPE SAPB-SAPWINTITL, " SPACE | |||
| lv_doc_type | TYPE TOAOM-DOC_TYPE, " SPACE | |||
| lv_positioninalffile | TYPE TOAOM, " SPACE | |||
| lv_noget | TYPE TOAOM, " SPACE | |||
| lv_pathoffile | TYPE TOAOM, " SPACE | |||
| lv_eof | TYPE TOAOM, " SPACE | |||
| lv_dalength | TYPE TOADL-DATALENGTH, " SPACE | |||
| lv_pfstatus | TYPE SY-PFKEY, " SPACE | |||
| lv_report | TYPE RS38M-PROGRAMM, " SPACE | |||
| lv_returncode | TYPE RS38M, " | |||
| lv_archiv_doc_index | TYPE SAPB-SAPADOKID, " SPACE | |||
| lv_error_communicationtable | TYPE SAPB, " | |||
| lv_archiv_id | TYPE TOAAR-ARCHIV_ID, " | |||
| lv_error_kernel | TYPE TOAAR, " | |||
| lv_objecttype | TYPE TOAV0-SAP_OBJECT, " SPACE | |||
| lv_object_id | TYPE TOAV0-OBJECT_ID, " SPACE | |||
| lv_ar_object | TYPE TOAV0-AR_OBJECT, " SPACE | |||
| lv_language | TYPE TOAV0, " SPACE | |||
| lv_sign | TYPE SAPB-SAPBZZ, " SPACE | |||
| lv_window_id | TYPE SAPB-SAPWINID. " SPACE |
|   CALL FUNCTION 'ARCHIVOBJECT_DISPLAY_SAMPLE' "Displaying FAX Documents from an External Storage System |
| EXPORTING | ||
| ARCHIV_DOC_ID | = lv_archiv_doc_id | |
| WINDOW_TITLE | = lv_window_title | |
| DOC_TYPE | = lv_doc_type | |
| POSITIONINALFFILE | = lv_positioninalffile | |
| NOGET | = lv_noget | |
| PATHOFFILE | = lv_pathoffile | |
| EOF | = lv_eof | |
| DALENGTH | = lv_dalength | |
| PFSTATUS | = lv_pfstatus | |
| REPORT | = lv_report | |
| ARCHIV_DOC_INDEX | = lv_archiv_doc_index | |
| ARCHIV_ID | = lv_archiv_id | |
| OBJECTTYPE | = lv_objecttype | |
| OBJECT_ID | = lv_object_id | |
| AR_OBJECT | = lv_ar_object | |
| LANGUAGE | = lv_language | |
| SIGN | = lv_sign | |
| WINDOW_ID | = lv_window_id | |
| IMPORTING | ||
| GOON | = lv_goon | |
| RETURNCODE | = lv_returncode | |
| EXCEPTIONS | ||
| ERROR_ARCHIV = 1 | ||
| ERROR_COMMUNICATIONTABLE = 2 | ||
| ERROR_KERNEL = 3 | ||
| . " ARCHIVOBJECT_DISPLAY_SAMPLE | ||
ABAP code using 7.40 inline data declarations to call FM ARCHIVOBJECT_DISPLAY_SAMPLE
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 AR_STATUS FROM TOAOM INTO @DATA(ld_goon). | ||||
| "SELECT single SAPADOKID FROM SAPB INTO @DATA(ld_archiv_doc_id). | ||||
| "SELECT single SAPWINTITL FROM SAPB INTO @DATA(ld_window_title). | ||||
| DATA(ld_window_title) | = ' '. | |||
| "SELECT single DOC_TYPE FROM TOAOM INTO @DATA(ld_doc_type). | ||||
| DATA(ld_doc_type) | = ' '. | |||
| DATA(ld_positioninalffile) | = ' '. | |||
| DATA(ld_noget) | = ' '. | |||
| DATA(ld_pathoffile) | = ' '. | |||
| DATA(ld_eof) | = ' '. | |||
| "SELECT single DATALENGTH FROM TOADL INTO @DATA(ld_dalength). | ||||
| DATA(ld_dalength) | = ' '. | |||
| "SELECT single PFKEY FROM SY INTO @DATA(ld_pfstatus). | ||||
| DATA(ld_pfstatus) | = ' '. | |||
| "SELECT single PROGRAMM FROM RS38M INTO @DATA(ld_report). | ||||
| DATA(ld_report) | = ' '. | |||
| "SELECT single SAPADOKID FROM SAPB INTO @DATA(ld_archiv_doc_index). | ||||
| DATA(ld_archiv_doc_index) | = ' '. | |||
| "SELECT single ARCHIV_ID FROM TOAAR INTO @DATA(ld_archiv_id). | ||||
| "SELECT single SAP_OBJECT FROM TOAV0 INTO @DATA(ld_objecttype). | ||||
| DATA(ld_objecttype) | = ' '. | |||
| "SELECT single OBJECT_ID FROM TOAV0 INTO @DATA(ld_object_id). | ||||
| DATA(ld_object_id) | = ' '. | |||
| "SELECT single AR_OBJECT FROM TOAV0 INTO @DATA(ld_ar_object). | ||||
| DATA(ld_ar_object) | = ' '. | |||
| DATA(ld_language) | = ' '. | |||
| "SELECT single SAPBZZ FROM SAPB INTO @DATA(ld_sign). | ||||
| DATA(ld_sign) | = ' '. | |||
| "SELECT single SAPWINID FROM SAPB INTO @DATA(ld_window_id). | ||||
| DATA(ld_window_id) | = ' '. | |||
Search for further information about these or an SAP related objects