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.
cancel
Showing results for 
Search instead for 
Did you mean: 

CALL FUNCTION ... DESTINATION ?

Former Member
0 Kudos

Hello,

I have got a report and a remote function module. Everything works fine.

I would like to call the remote function module in different systems. Therefore, I use a loop stmt in my report from which the remote function tool is called. Within this loop, RFC destinations are read from an internal table. But the stmt:

CALL 'func'

DESTINATION <b>'dest'</b>.

awaits after DESTINATION a character. Instead I can not put in a variable like <i>current_dest</i>.

Does anybody know, how I could use a variable for as a destination?

thx,

holger

1 ACCEPTED SOLUTION

abdul_hakim
Active Contributor
0 Kudos

Hi,

define as foll,

DATA dest LIKE rfcdest.

Abdul

4 REPLIES 4

abdul_hakim
Active Contributor
0 Kudos

Hi,

define as foll,

DATA dest LIKE rfcdest.

Abdul

0 Kudos

sorry, but i get this error message:

"RFCDEST" must be a flat strucutre. You cannnot use a strucutre of internal table as a component.

??

0 Kudos

its :

like RFCDES-RFCDEST.

you can go to se11 and see the table RFCDES.

cheers

Former Member
0 Kudos

HI holger,

if you r making rfc call to a remote system..you must specify the details in sm59 transaction..here you create a destination say 'ZTEST' here you can give all the details for connection..

save it.

now you can call your rfc as

call function <rfc name>

destination ZTEST

exporting..

table..

hope this will help you.

visit

http://help.sap.com/saphelp_47x200/helpdata/en/22/04262b488911d189490000e829fbbd/frameset.htm

to know how to configure detination in SM59.

plz reward points if it helps you.