Skip to Content
0
Former Member
Aug 10, 2007 at 08:10 AM

Fieldcatalog merge

21 Views

Hi,

i have written a sample code to display fieldcat like given below.. if i execute this code its going to dump and there its showing an error message like..

" The READ REPORT statement allows you to copy a program text into an

internal table. The occupied line length in the program text must not

exceed the width of the internal table. The internal table "\FUNCTION=K_KKB_FIELDCAT_MERGE\DATA=L_ABAP_SOURCE[]" is 72 characters wide. The program line is 140 characters wide.".. here if i pass the structure name to I_STRUCTURE instead of internal table its giving the o/p....can u please try to solve this... i am working with ECC 6.0 ver..

Tables: vbak.

type-pools: slis.

**DATA: begin of st_vbak.

**INCLUDE STRUCTURE ZST_VBAK.

**DATA: END OF ST_VBAK.

DATA: BEGIN OF IT_VBAK OCCURS 0,

vbeln LIKE vbak-vbeln,

erdat LIKE vbak-erdat,

erzet LIKE vbak-erzet,

ernam LIKE vbak-ernam,

audat LIKE vbak-audat,

END OF IT_VBAK.

data: repid type sy-repid.

select-options: s_vbeln for vbak-vbeln.

select vbeln erdat erzet ernam audat vbtyp gwldt waerk vkorg vtweg spart guebg gueen from vbak into table it_vbak where vbeln in s_vbeln.

repid = sy-repid.

perform filed_cat.

FORM filed_cat .

CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE'

EXPORTING

I_PROGRAM_NAME = REPID

I_INTERNAL_TABNAME = 'IT_VBAK'

I_INCLNAME = REPID

CHANGING

CT_FIELDCAT = it_fieldcat

Regards.

Laxman.P