Start of Content Area

RfcCall  Locate the document in its SAP Library structure

This functin calls an ABAP function module via RFC:

RFC_RC SAP_API RfcCall(RFC_HANDLE handle,
char * function,
RFC_PARAMETER * parameters,
RFC_TABLE * tables);

The structures RFC_PARAMETER and RFC_TABLE contain names and descriptions of the ‘exporting’ parameters and tables specified in the function's interface. Tables can only be internal ABAP tables. The function returns after the call-request is sent. If the function returns RFC_OK there is no guarantee that the call has already been received by the target system.

This function is defined in SAPRFC.H.

Return Value:

Function Parameters:

connection handle

function module to call

‘exporting’ parameters

‘tables’ parameters

Note

RfcCall can fail because you called RfcOpen with an invalid password. See RfcOpen for more information.

Example

Calling the function module RFC_SYSTEM_INFO

RFC_RC rfc_rc;
RFC_PARAMETER exporting[32];
RFC_TABLE tables[32];

exporting[0].name = NULL;
tables[0].name = NULL;

rfc_rc = RfcCall(handle, "RFC_SYSTEM_INFO", exporting, tables);

if(rfc_rc != RFC_OK)

{

...