Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Using the FM LVC_FIELDCATALOG_MERGE

Hi everybody!

I'm trying to generate an automatic fieldcat from an internal table using the FM 'LVC_FIELDCATALOG_MERGE' but it doesn't work! I don't know what I'm doing wrong!

Can anybody help me?

Here is my code.

types:

BEGIN OF type,

matnr type makt-matnr,

maktx type makt-maktx,

spras type makt-spras,

END OF type.

data: tabela type STANDARD TABLE OF type,

fieldcat type STANDARD TABLE OF lvc_s_fcat.

CALL FUNCTION 'LVC_FIELDCATALOG_MERGE'

EXPORTING

  • I_BUFFER_ACTIVE =

I_STRUCTURE_NAME = 'TYPE'

  • I_CLIENT_NEVER_DISPLAY = 'X'

  • I_BYPASSING_BUFFER =

I_INTERNAL_TABNAME = 'TABELA'

CHANGING

ct_fieldcat = fieldcat

  • EXCEPTIONS

  • INCONSISTENT_INTERFACE = 1

  • PROGRAM_ERROR = 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.

BREAK-POINT.

Tags:
Former Member
Not what you were looking for? View more on this topic or Ask a question