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

call function with rfc or not ?

Former Member
0 Likes
795

How can I know that an function is called by rfc or not ?

info : The caller is not R/3 system. This web interface...

thanks in advance

5 REPLIES 5
Read only

suresh_datti
Active Contributor
0 Likes
749

Hi Stephen,

not sure if this is what you meant.. but you can make an RFC call only if the said function is remotely enabled.. pl verify the attributes of the function module.

Regards,

Suresh Datti

Read only

0 Likes
749

I have a REMOTE FUNCTION CALL...

In the code of my function, I would like to know if it was called remotly or locally...

regards,

Read only

Former Member
0 Likes
749

Hi Stephan,

Try this FM

TRANSACTION_CALL_VIA_RFC

Data : v_bdi_line type bdi_line.

Call Function 'TRANSACTION_CALL_VIA_RFC'

Exporting

tcode = sy-tcode.

importing

transaction_data = v_bdi_line.

Exceptions

tcode_not_exist = 1.

if sy-subrc ne 0.

It means it is RFC call.

endif.

Reward points if it helps you.

Regards,

Sudhakar.

Read only

0 Likes
749

Hi Stephan,

You have a syntax for calling the particular RFC function remotely. The syntax is below :

CALL FUNCTION 'Function name ' DESTINATION 'Destination Name'

exports

imports

tables

exceptions .

If you want to run that particular function remotely in particular destination specify the destination name.

Then that FM will run remotely else locally if you not specify any destination.

Hope this helps you.....

Regards,

Vamshi

Read only

0 Likes
749

when the FM is called from web interface

syst-cprog will hold value "SAPMHTTP"

Regards

Raja