2008 Aug 04 2:50 PM
HI.
I created ALV by Function module 'REUSE_ALV_FIELDCATALOG_MERGE'.its giving DUMP like inconsistent interface i.e. sy-subrc = 1.
Could you tell me the reasons.how can i resolve this problem.
Regards.
jay
HI.
I created ALV by Function module 'REUSE_ALV_FIELDCATALOG_MERGE'.its giving DUMP like inconsistent interface i.e. sy-subrc = 1.
Could you tell me the reasons.how can i resolve this problem.
Regards.
jay
2008 Aug 04 2:54 PM
Hi,
I hope the following links will help you,
https://forums.sdn.sap.com/click.jspa?searchID=14815661&messageID=5345853
https://forums.sdn.sap.com/click.jspa?searchID=14815661&messageID=5346379
https://forums.sdn.sap.com/click.jspa?searchID=14815661&messageID=5601456
Regards,
Harish
2008 Aug 04 2:57 PM
You need to declare the Internal table in the below mentioned way . and Use LIKE instead of TYPE when declaring the fields.
data: begin of itab occurs 0,
vbeln like vbap-vbeln,
matnr like vbap-matnr,
end of itab.
CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE'
EXPORTING
i_program_name = sy-repid
i_internal_tabname = 'ITAB'
i_inclname = sy-repid " <=-==this is important
CHANGING
ct_fieldcat = it_fieldcat[]
EXCEPTIONS
inconsistent_interface = 1
program_error = 2
OTHERS = 3.
IF sy-subrc <> 0.
ENDIF.
2008 Aug 04 3:09 PM
2008 Aug 04 3:18 PM
Hi,
You need to do the following steps to get your problem solved
1.) Declare the TYPES for the data of internal table. and while declaring the data you need to use LIKE and not TYPE otherwise it will throw dump.
types: begin of ty_itab,
matnr like mara-matnr,
end of ty_itab.
2.) Define the internal table
data: t_itab type table of ty_itab with header line.
3.) pass the program name in local variable
l_repid = sy-repid
4.) pass the values to function module
call function 'REUSE_ALV_FIELDCATALOG_MERGE'
exporting
i_program_name = l_repid" Program Name
i_internal_tabname = 'T_ITAB' " Name of output table
changing
ct_fieldcat = gt_fieldcat " Field catalog with
exceptions
inconsistent_interface = 1
program_error = 2
others = 3
Please reward if you find the answer useful.
Thanks,
Kamesh
| User | Count |
|---|---|
| 4 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |