SAP TEXT_INTERFACE_WITH_PROTOCOL Function Module for Correspondence: Create Document (with Error Log)
TEXT_INTERFACE_WITH_PROTOCOL is a standard text interface with protocol SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used for Correspondence: Create Document (with Error Log) 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 text interface with protocol FM, simply by entering the name TEXT_INTERFACE_WITH_PROTOCOL into the relevant SAP transaction such as SE37 or SE38.
Function Group: FVDD_ADDON
Program Name: SAPLFVDD_ADDON
Main Program: SAPLFVDD_ADDON
Appliation area: F
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function TEXT_INTERFACE_WITH_PROTOCOL 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 'TEXT_INTERFACE_WITH_PROTOCOL'"Correspondence: Create Document (with Error Log).
EXPORTING
* ADRTYP = ' ' "Address Category
* POPUP_TTXBS = '*' "Anwender-Dialog Druckoptionen: 'X' = JA
* P_USER_EXIT = ' ' "freier Parameter für Customer Function
* RANTYP = '1' "Contract Type
* STICHTAG = SY-DATUM "Datum für Ermittlung der Partner-Daten
* SUBANWDG = ' ' "Subapplication
* BRFNM = ' ' "Brief-Name
* BRIEFDATUM = SY-DATUM "Datum, das im Briefkopf gedruckt wird
* BUKRS = '0001' "Company Code
* DRUPARM = ' ' "Print Parameters
* FPROTOKOLL = '*' "
* FSYS_STEUERUNG = ' ' "
* PARTNR = ' ' "Partner-Nr. für Anschr.findung und Archivierung
* POPUP_PRINT_OPTIONS = '*' "Anwender-Dialog Druckoptionen: 'X' = JA
IMPORTING
ERGEBNIS = "Druck-Ergebnis
RC = "
TABLES
T_PROTOKOLL = "
Customer Function user exits
Below is a list of CUSTOMER FUNCTION exit user exits that are available within this program and maybe relevant for this FM.EXIT_SAPLFVDD_ADDON_001 User Exit for FB TEXT_INTERFACE
EXIT_SAPLFVDD_ADDON_002 User Exit for Document Selection
EXIT_SAPLFVDD_ADDON_003 User Exit for Selecting Correspondence Activities
IMPORTING Parameters details for TEXT_INTERFACE_WITH_PROTOCOL
ADRTYP - Address Category
Data type: BU_ADRKINDDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
POPUP_TTXBS - Anwender-Dialog Druckoptionen: 'X' = JA
Data type: TTXBF-JBSTAUSWDefault: '*'
Optional: Yes
Call by Reference: No ( called with pass by value option)
P_USER_EXIT - freier Parameter für Customer Function
Data type:Default: ' '
Optional: Yes
Call by Reference: No ( called with pass by value option)
RANTYP - Contract Type
Data type: TTXBF-RANTYPDefault: '1'
Optional: Yes
Call by Reference: No ( called with pass by value option)
STICHTAG - Datum für Ermittlung der Partner-Daten
Data type: SY-DATUMDefault: SY-DATUM
Optional: Yes
Call by Reference: No ( called with pass by value option)
SUBANWDG - Subapplication
Data type: TTXBF-SUBANWDGDefault: ' '
Optional: Yes
Call by Reference: No ( called with pass by value option)
BRFNM - Brief-Name
Data type: TTXBF-BRFNMDefault: ' '
Optional: Yes
Call by Reference: No ( called with pass by value option)
BRIEFDATUM - Datum, das im Briefkopf gedruckt wird
Data type: SY-DATUMDefault: SY-DATUM
Optional: Yes
Call by Reference: No ( called with pass by value option)
BUKRS - Company Code
Data type: T001-BUKRSDefault: '0001'
Optional: Yes
Call by Reference: No ( called with pass by value option)
DRUPARM - Print Parameters
Data type: ITCPODefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
FPROTOKOLL -
Data type: TTXBF-JFPRODefault: '*'
Optional: Yes
Call by Reference: No ( called with pass by value option)
FSYS_STEUERUNG -
Data type:Default: ' '
Optional: Yes
Call by Reference: No ( called with pass by value option)
PARTNR - Partner-Nr. für Anschr.findung und Archivierung
Data type: BU_PARTNERDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
POPUP_PRINT_OPTIONS - Anwender-Dialog Druckoptionen: 'X' = JA
Data type: TTXBF-JSPFBDefault: '*'
Optional: Yes
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for TEXT_INTERFACE_WITH_PROTOCOL
ERGEBNIS - Druck-Ergebnis
Data type: ITCPPOptional: No
Call by Reference: No ( called with pass by value option)
RC -
Data type: SY-SUBRCOptional: No
Call by Reference: No ( called with pass by value option)
TABLES Parameters details for TEXT_INTERFACE_WITH_PROTOCOL
T_PROTOKOLL -
Data type: LFVDDPOptional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for TEXT_INTERFACE_WITH_PROTOCOL 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_adrtyp | TYPE BU_ADRKIND, " SPACE | |||
| lv_ergebnis | TYPE ITCPP, " | |||
| lt_t_protokoll | TYPE STANDARD TABLE OF LFVDDP, " | |||
| lv_popup_ttxbs | TYPE TTXBF-JBSTAUSW, " '*' | |||
| lv_p_user_exit | TYPE TTXBF, " ' ' | |||
| lv_rantyp | TYPE TTXBF-RANTYP, " '1' | |||
| lv_stichtag | TYPE SY-DATUM, " SY-DATUM | |||
| lv_subanwdg | TYPE TTXBF-SUBANWDG, " ' ' | |||
| lv_rc | TYPE SY-SUBRC, " | |||
| lv_brfnm | TYPE TTXBF-BRFNM, " ' ' | |||
| lv_briefdatum | TYPE SY-DATUM, " SY-DATUM | |||
| lv_bukrs | TYPE T001-BUKRS, " '0001' | |||
| lv_druparm | TYPE ITCPO, " SPACE | |||
| lv_fprotokoll | TYPE TTXBF-JFPRO, " '*' | |||
| lv_fsys_steuerung | TYPE TTXBF, " ' ' | |||
| lv_partnr | TYPE BU_PARTNER, " SPACE | |||
| lv_popup_print_options | TYPE TTXBF-JSPFB. " '*' |
|   CALL FUNCTION 'TEXT_INTERFACE_WITH_PROTOCOL' "Correspondence: Create Document (with Error Log) |
| EXPORTING | ||
| ADRTYP | = lv_adrtyp | |
| POPUP_TTXBS | = lv_popup_ttxbs | |
| P_USER_EXIT | = lv_p_user_exit | |
| RANTYP | = lv_rantyp | |
| STICHTAG | = lv_stichtag | |
| SUBANWDG | = lv_subanwdg | |
| BRFNM | = lv_brfnm | |
| BRIEFDATUM | = lv_briefdatum | |
| BUKRS | = lv_bukrs | |
| DRUPARM | = lv_druparm | |
| FPROTOKOLL | = lv_fprotokoll | |
| FSYS_STEUERUNG | = lv_fsys_steuerung | |
| PARTNR | = lv_partnr | |
| POPUP_PRINT_OPTIONS | = lv_popup_print_options | |
| IMPORTING | ||
| ERGEBNIS | = lv_ergebnis | |
| RC | = lv_rc | |
| TABLES | ||
| T_PROTOKOLL | = lt_t_protokoll | |
| . " TEXT_INTERFACE_WITH_PROTOCOL | ||
ABAP code using 7.40 inline data declarations to call FM TEXT_INTERFACE_WITH_PROTOCOL
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.| DATA(ld_adrtyp) | = ' '. | |||
| "SELECT single JBSTAUSW FROM TTXBF INTO @DATA(ld_popup_ttxbs). | ||||
| DATA(ld_popup_ttxbs) | = '*'. | |||
| DATA(ld_p_user_exit) | = ' '. | |||
| "SELECT single RANTYP FROM TTXBF INTO @DATA(ld_rantyp). | ||||
| DATA(ld_rantyp) | = '1'. | |||
| "SELECT single DATUM FROM SY INTO @DATA(ld_stichtag). | ||||
| DATA(ld_stichtag) | = SY-DATUM. | |||
| "SELECT single SUBANWDG FROM TTXBF INTO @DATA(ld_subanwdg). | ||||
| DATA(ld_subanwdg) | = ' '. | |||
| "SELECT single SUBRC FROM SY INTO @DATA(ld_rc). | ||||
| "SELECT single BRFNM FROM TTXBF INTO @DATA(ld_brfnm). | ||||
| DATA(ld_brfnm) | = ' '. | |||
| "SELECT single DATUM FROM SY INTO @DATA(ld_briefdatum). | ||||
| DATA(ld_briefdatum) | = SY-DATUM. | |||
| "SELECT single BUKRS FROM T001 INTO @DATA(ld_bukrs). | ||||
| DATA(ld_bukrs) | = '0001'. | |||
| DATA(ld_druparm) | = ' '. | |||
| "SELECT single JFPRO FROM TTXBF INTO @DATA(ld_fprotokoll). | ||||
| DATA(ld_fprotokoll) | = '*'. | |||
| DATA(ld_fsys_steuerung) | = ' '. | |||
| DATA(ld_partnr) | = ' '. | |||
| "SELECT single JSPFB FROM TTXBF INTO @DATA(ld_popup_print_options). | ||||
| DATA(ld_popup_print_options) | = '*'. | |||
Search for further information about these or an SAP related objects