SAP RFC_TCPIP_CONNECTION_OPEN Function Module for
RFC_TCPIP_CONNECTION_OPEN is a standard rfc tcpip connection open SAP function module available within SAP R/3 or S/4 Hana systems, depending on your version and release level. It is used to perform a specific ABAP function and below is the pattern details, 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 rfc tcpip connection open FM, simply by entering the name RFC_TCPIP_CONNECTION_OPEN into the relevant SAP transaction such as SE37 or SE38.
Function Group: CRFC
Program Name: SAPLCRFC
Main Program: SAPLCRFC
Appliation area: S
Release date: N/A
Mode(Normal, Remote etc): Normal Function Module
Update:

Function RFC_TCPIP_CONNECTION_OPEN 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 'RFC_TCPIP_CONNECTION_OPEN'".
EXPORTING
COMMAND = "
* TRACE = ' ' "
HOST = "
* RFCCONVERT = ' ' "
* RFCCONVX = '00000000' "
* RFCUNICODE = '1' "
* RFCBITMAP = '00000000' "Bitmap for Variable Options in RFCOPT
* RFCGWHOST = ' ' "Gateway host name
* RFCGWSERV = ' ' "Gateway Service
IMPORTING
DESTINATION = "
EXCEPTIONS
CANNOT_OPEN = 1
IMPORTING Parameters details for RFC_TCPIP_CONNECTION_OPEN
COMMAND -
Data type: RFCOPT-RFCEXECOptional: No
Call by Reference: No ( called with pass by value option)
TRACE -
Data type: RFCOPT-RFCTRACEDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
HOST -
Data type: RFCOPT-RFCHOSTOptional: No
Call by Reference: No ( called with pass by value option)
RFCCONVERT -
Data type: RFCDISPLAY-RFCCONVERTDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
RFCCONVX -
Data type: RFCRAW04Default: '00000000'
Optional: Yes
Call by Reference: No ( called with pass by value option)
RFCUNICODE -
Data type: RFCDISPLAY-RFCUNICODEDefault: '1'
Optional: Yes
Call by Reference: No ( called with pass by value option)
RFCBITMAP - Bitmap for Variable Options in RFCOPT
Data type: RFCRAW04Default: '00000000'
Optional: Yes
Call by Reference: No ( called with pass by value option)
RFCGWHOST - Gateway host name
Data type: RFCGWHOSTDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
RFCGWSERV - Gateway Service
Data type: RFCGWSERVDefault: SPACE
Optional: Yes
Call by Reference: No ( called with pass by value option)
EXPORTING Parameters details for RFC_TCPIP_CONNECTION_OPEN
DESTINATION -
Data type: RFCDES-RFCDESTOptional: No
Call by Reference: No ( called with pass by value option)
EXCEPTIONS details
CANNOT_OPEN -
Data type:Optional: No
Call by Reference: No ( called with pass by value option)
Copy and paste ABAP code example for RFC_TCPIP_CONNECTION_OPEN 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_command | TYPE RFCOPT-RFCEXEC, " | |||
| lv_cannot_open | TYPE RFCOPT, " | |||
| lv_destination | TYPE RFCDES-RFCDEST, " | |||
| lv_trace | TYPE RFCOPT-RFCTRACE, " SPACE | |||
| lv_host | TYPE RFCOPT-RFCHOST, " | |||
| lv_rfcconvert | TYPE RFCDISPLAY-RFCCONVERT, " SPACE | |||
| lv_rfcconvx | TYPE RFCRAW04, " '00000000' | |||
| lv_rfcunicode | TYPE RFCDISPLAY-RFCUNICODE, " '1' | |||
| lv_rfcbitmap | TYPE RFCRAW04, " '00000000' | |||
| lv_rfcgwhost | TYPE RFCGWHOST, " SPACE | |||
| lv_rfcgwserv | TYPE RFCGWSERV. " SPACE |
|   CALL FUNCTION 'RFC_TCPIP_CONNECTION_OPEN' " |
| EXPORTING | ||
| COMMAND | = lv_command | |
| TRACE | = lv_trace | |
| HOST | = lv_host | |
| RFCCONVERT | = lv_rfcconvert | |
| RFCCONVX | = lv_rfcconvx | |
| RFCUNICODE | = lv_rfcunicode | |
| RFCBITMAP | = lv_rfcbitmap | |
| RFCGWHOST | = lv_rfcgwhost | |
| RFCGWSERV | = lv_rfcgwserv | |
| IMPORTING | ||
| DESTINATION | = lv_destination | |
| EXCEPTIONS | ||
| CANNOT_OPEN = 1 | ||
| . " RFC_TCPIP_CONNECTION_OPEN | ||
ABAP code using 7.40 inline data declarations to call FM RFC_TCPIP_CONNECTION_OPEN
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 RFCEXEC FROM RFCOPT INTO @DATA(ld_command). | ||||
| "SELECT single RFCDEST FROM RFCDES INTO @DATA(ld_destination). | ||||
| "SELECT single RFCTRACE FROM RFCOPT INTO @DATA(ld_trace). | ||||
| DATA(ld_trace) | = ' '. | |||
| "SELECT single RFCHOST FROM RFCOPT INTO @DATA(ld_host). | ||||
| "SELECT single RFCCONVERT FROM RFCDISPLAY INTO @DATA(ld_rfcconvert). | ||||
| DATA(ld_rfcconvert) | = ' '. | |||
| DATA(ld_rfcconvx) | = '00000000'. | |||
| "SELECT single RFCUNICODE FROM RFCDISPLAY INTO @DATA(ld_rfcunicode). | ||||
| DATA(ld_rfcunicode) | = '1'. | |||
| DATA(ld_rfcbitmap) | = '00000000'. | |||
| DATA(ld_rfcgwhost) | = ' '. | |||
| DATA(ld_rfcgwserv) | = ' '. | |||
Search for further information about these or an SAP related objects