Show TOC

Introduction to RFC Client ProgramsLocate this document in the navigation structure

Use

All RFC client programs have to establish an RFC connection to an SAP system:

Possible Logon Users

  • Logon to an SAP system is possible with a DIALOG user or a CPIC user.

  • Logon to an R/2 System is only possible with a CPIC user.

Getting Connected with the RFC Library as of Release 3.0C

An RFC connection can be established via an entry in the saprfc.ini file. Using this feature, you need not have any sideinfo file except for connecting to an R/2 System (IBM).

  • The saprfc.ini file has the same meaning as the sideinfo file, but all RFC features, such as RFC with SAPGUI, ABAP-debug,... can be defined in that file.

  • Moreover, most new RFC features to be developed in the future can be used without changing the RFC client program sources.

The sideinfo file is needed for communication via CPI-C and includes some parameters necessary for establishing a CPI-C connection.

If the local sideinfo is not used, all the parameters required must be passed on to the RFC library using the call RfcConnArgv before the RfcOpen is submitted or defined in the parameter RFC_OPTIONS of RfcOpen.

An RFC function is called by RfcCall. The function RfcCall returns after the call request is sent.

The function RfcReceive allows to receive the answer to an RFC call and must be called after RfcCall was issued. The function RfcReceive waits until the answer is received.

Moreover, there is a function which can issue an RFC call synchronously: RfcCallReceive waits until the returned answer will be received.

Typical examples of RFC client programs are sapinfo.c, startrfc.c and srfctest.c which are included in the RFC SDK.