on 10-24-2007 12:50 AM
Hi,
I want to call Synch RFC call in ABAP programe.
In ABAP programe do i need to give XI destination for calling RFC. If possible plz provide sample code for this purpose. please help me out.
thanks
siva
null
Siva,
Check block below...I think you are looking for this..
/people/swaroopa.vishwanath/blog/2006/12/28/send-rfc-to-sap-xi-150-asynchronous
Nilesh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Siva,
Code is there( Inside Text Box)..I am copy/pasting for you..
&----
*& Report ZRFC_READ_TABLE_EOFM *
*& *
&----
*& *
*& *
&----
REPORT zrfc_read_table_eofm.
data: i_options like RFC_DB_OPT occurs 0,
i_fields like RFC_DB_FLD occurs 0,
i_data like TAB512 occurs 0,
i_table_name like dd02L occurs 0 with header line.
SELECTION-SCREEN: BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.
PARAMETERS: tab_name like DD02L-TABNAME.
SELECTION-SCREEN: END OF BLOCK b1.
CALL FUNCTION 'RFC_READ_TABLE'
EXPORTING
query_table = tab_name
DELIMITER = ' '
NO_DATA = ' '
ROWSKIPS = 0
ROWCOUNT = 0
tables
OPTIONS = i_options
fields = i_fields
data = i_data
EXCEPTIONS
TABLE_NOT_AVAILABLE = 1
TABLE_WITHOUT_DATA = 2
OPTION_NOT_VALID = 3
FIELD_NOT_VALID = 4
NOT_AUTHORIZED = 5
DATA_BUFFER_EXCEEDED = 6
OTHERS = 7
.
*IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
*ENDIF.
I_TABLE_NAME-TABNAME = tab_name.
append I_table_name.
CALL FUNCTION 'ZRFC_READ_TABLE_EOFM' IN BACKGROUND TASK DESTINATION
'NWDCLNT100'
TABLES
i_data = i_data
i_options = i_options
i_fields = i_fields
i_table_name = i_table_name
EXCEPTIONS
COMMUNICATION_FAILURE = 1
SYSTEM_FAILURE = 2
OTHERS = 3
.
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
commit work.
Let me know if you need more details.
Nilesh
Hi Siva,
In blog can you see ..
&----
*& Report ZRFC_READ_TABLE_EOFM *
*& *
&----
*& *
*& *
&----
This is nothing but "Text Area"..there is scroll bar on left hand side for this text area. Scroll down ..you will see complete code.
This how you call RFC in abap program..
CALL FUNCTION 'ZRFC_READ_TABLE_EOFM' IN BACKGROUND TASK DESTINATION
'NWDCLNT100'
TABLES
i_data = i_data
i_options = i_options
i_fields = i_fields
i_table_name = i_table_name
EXCEPTIONS
COMMUNICATION_FAILURE = 1
SYSTEM_FAILURE = 2
OTHERS = 3
.
"sorry to ask these small things"
No problem. We are here to help each other
Let me know if you need more details.
Nilesh
User | Count |
---|---|
90 | |
10 | |
10 | |
10 | |
7 | |
7 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.