Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
Showing results for 
Search instead for 
Did you mean: 

How to make a RFC program and its pre-requisites to know?

Former Member
0 Kudos

Hi there,

I have been asked to make an RFC interface. This is the first time I am making any RFC. Can you please tell me how to go to make an RFC? What are the pre-requisites before making an RFC.

thanks in advance.


Active Contributor
0 Kudos


Check these links -

<a href=""></a>

<a href=""></a>



Reward all helpful replies.

Former Member
0 Kudos

Ganesh ,

For this You have to create RFC FM.



The RFC Interface

A remote function call is a call to a function module running in a system different from the caller's. The remote function can also be called from within the same system (as a remote call), but usually caller and callee will be in different systems.

In the SAP System, the ability to call remote functions is provided by the Remote Function Call interface system (RFC). RFC allows for remote calls between two SAP Systems (R/3 or R/2), or between an SAP System and a non-SAP System.

RFC consists of the following interfaces:

A calling interface for ABAP programs

Any ABAP program can call a remote function using the CALL FUNCTION...DESTINATION statement. The DESTINATION parameter tells the SAP System that the called function runs in a system other than the caller's. RFC communication with the remote system happens as part of the CALL FUNCTION statement.

RFC functions running in an SAP System must be actual function modules, and must be registered in the SAP System as "remote".

When both caller and called program are ABAP programs, the RFC interface provides both partners to the communication. The caller may be any ABAP program, while the called program must be a function module registered as remote.

The topic Calling Remote Function Modules in ABAP provides details on calling function modules registered as remote.

The topic Writing Remote Function Modules in ABAP provides information on writing function modules that you want to call remotely.

Calling interfaces for non-SAP programs

When either the caller or the called partner is a non-ABAP program, it must be programmed to play the other partner in an RFC communication.

CREATE RFC FM>>>>>>>>>>>>>


To help implement RFC partner programs in non-SAP Systems, SAP provides

External Interfaces

RFC-based and GUI-based interfaces can be used by external programs to call function modules in SAP R/2 or R/3 systems and execute them in these systems. Vice versa, ABAP programs in R/2 or R/3 can use the functions provided by external programs via these interfaces.

To implement a remote function module in ABAP, perform the following steps:

Register the module as remotely callable in the RFC server system.

In the function module Administration screen (transaction code SE37), set the field Can be called via REMOTE CALL. Registering a module as remote causes an RFC stub to be generated for it.

Write the code for the function module.


Displaying, Maintaining and Testing Destinations

To display, create or modify destinations, choose Tools ® Administration ® Administration ® Network ® RFC destinations or enter transaction code SM59.

Remote Destinations are stored in table RFCDES. The RFCDES table describes logical destinations for remote function calls.

It is not possible to maintain the RFCDES table directly.

You can also access logical destinations via the Implementation Guide (IMG) by choosing Tools ® AcceleratedSAP ® Customizing ® Execute Project ® SAP Reference IMG.

In the Implementation Guide, expand the following hierarchy structure:


Application Link Enabling (ALE)

Sending and Receiving Systems

Systems in Network

Define Target Systems for RFC Calls

Displaying Destinations

The initial screen for this transaction displays a tree:

Different connection types (i.e. partner systems or programs) are possible. For further information, see Types of Destinations.

To display all information for a given destination, double-click it, or place the cursor on it and press F2 .

To search for a destination, press the Find button and specify your selection. You get a list of all entries matching your selection. Place the cursor on the one you want, and press F2 or simply double-click the destination. All information for the given entry appears.

Creating Destinations

On the destinations overview screen (transaction code SM59), the connection types and all existing destinations are displayed in a tree structure.

All available connection types are explained in Types of Destinations.

To create a new RFC destination, press the Create button. A new screen is displayed with empty fields for you to fill in.

If you want to create a new destination

As you create a remote destination, you can specify a particular application server or a group of servers for a balanced distribution of system load.

For details of the destination parameters, see Entering Destination Parameters.

Changing Existing Destinations

On the destinations overview screen (transaction code SM59), the connection types and all existing destinations are displayed in a tree structure.

You can display all information for a given destination by double-clicking it or pressing F2 on it.

To change an existing destination, double-click it, or place the cursor on it and press the Change button.

For details of the destination parameters, see Entering Destination Parameters.

Testing Destinations

To test a destination, choose the appropriate function from the Test menu.

Connection (also available via the Test connection pushbutton)

Authorization (checks logon data)

Local network (provides a list of application servers)

Pls. reward if useful

Former Member
0 Kudos


Refer to the link below:

It contains pdf document on RFC programming in ABAP & to call RFC betwen two SAP systems , all you have to do is insert a 'CALL FUNCTION' statement with the addition of the 'DESTINATION' parameter pointing to your destination SAP system. A list of RFC destinations can be viewed via transaction SM59.

call function 'Z_GET_USER_IDS' destination 'DEV_500'


userid = ld_userid.

Hope this helps.

Reward if helpful.



Former Member
0 Kudos

thank you all..