Skip to Content
author's profile photo Former Member
Former Member

Semi Automatic Field catalog

Hi Experts,

I have to display 20-25 fields in o/p.Hence i have used semi-automatic field catalog.

it_vendor is internal table having fields from table lfa1,lfb1,lfbw,lfbk.

CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE'

EXPORTING

I_PROGRAM_NAME = sy-repid

I_INTERNAL_TABNAME = 'IT_VENDOR'

  • I_STRUCTURE_NAME =

  • I_CLIENT_NEVER_DISPLAY = 'X'

  • I_INCLNAME =

  • I_BYPASSING_BUFFER =

  • I_BUFFER_ACTIVE =

CHANGING

ct_fieldcat = pt_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.

but i am getting dump ,

Type conflict when calling function module "REUSE_ALV_FIELDCATALOG_MERGE".

Please suggest.

Rgds,

Kaustubh.

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

3 Answers

  • Best Answer
    Posted on Feb 25, 2009 at 10:36 AM

    Hi,

    It doesnt work in ECC, build manually fieldcatalog. Refer Below code

    it_fieldcat-fieldname = 'ERDAT'.

    it_fieldcat-seltext_m = text-005.

    it_fieldcat-col_pos = 0.

    it_fieldcat-outputlen = 8.

    it_fieldcat-emphasize = 'X'.

    it_fieldcat-key = 'X'.

    APPEND it_fieldcat TO it_fieldcat.

    CLEAR it_fieldcat.

    it_fieldcat-fieldname = 'OLTOT'.

    it_fieldcat-seltext_m = text-006.

    it_fieldcat-col_pos = 1.

    it_fieldcat-outputlen = 4.

    APPEND it_fieldcat TO it_fieldcat.

    CLEAR it_fieldcat.

    it_fieldcat-fieldname = 'SOTOT'.

    it_fieldcat-seltext_m = text-007.

    it_fieldcat-col_pos = 2.

    it_fieldcat-outputlen = 4.

    APPEND it_fieldcat TO it_fieldcat.

    CLEAR it_fieldcat.

    it_fieldcat-fieldname = 'COREBUS'.

    it_fieldcat-seltext_m = text-008.

    it_fieldcat-col_pos = 3.

    it_fieldcat-outputlen = 15.

    APPEND it_fieldcat TO it_fieldcat.

    CLEAR it_fieldcat.

    it_fieldcat-fieldname = 'ONBULK'.

    it_fieldcat-seltext_m = text-009.

    it_fieldcat-col_pos = 4.

    it_fieldcat-outputlen = 15.

    APPEND it_fieldcat TO it_fieldcat.

    CLEAR it_fieldcat.

    Regards,

    Prashant

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Feb 25, 2009 at 10:40 AM

    Hi

    Have a look at this wiki.This will explains you the exact way, to do it.

    [https://wiki.sdn.sap.com/wiki/display/ABAP/Fieldcatalogtypes]

    Regards

    Hareesh

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Feb 25, 2009 at 11:26 AM

    Hi kaustabh,

    instead of passing inetrnal table pass its structure as export parameter and pt_fieldcat shd be of type

    slis_t_fieldcat_alv..

    CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE'

    EXPORTING

    I_PROGRAM_NAME = sy-repid

    *I_INTERNAL_TABNAME = 'IT_VENDOR'

    I_STRUCTURE_NAME = 'FS_VENDOR'

    *I_CLIENT_NEVER_DISPLAY = 'X'

    *I_INCLNAME =

    *I_BYPASSING_BUFFER =

    *I_BUFFER_ACTIVE =

    CHANGING

    ct_fieldcat = pt_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.

    Regards,

    Mdi.Deeba

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.