Skip to Content
avatar image
Former Member

F4 Help ALV Grid using

Hi All,

I am using REUSE_ALV_GRID_DISPLAY for Delivery block(VBAK-LIFSK) field is an Editable field. Now I am trying to get the F4 help on the ALV Grid for that Column cell. I checked the below link but the link is for lvc_t_fcat.

https://archive.sap.com/discussions/thread/3215580

I am using slis_t_fieldcat_alv. I did not find the f4availabl slis_t_fieldcat_alv. How to achieve the F4 help using slis_t_fieldcat_alv with REUSE_ALV_GRID_DISPLAY. Please suggest.

Thanks,

HT

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • Best Answer
    Jan 22 at 05:52 PM

    VBAK-LIFSK is a field with a foreign key, so if you fill correctly your field catalog, you should get F4 as demonstrated here:

    Done with this quick and dirty code:

    REPORT.
    DATA lt_fieldcat TYPE slis_t_fieldcat_alv.
    CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE'
      EXPORTING
        i_structure_name = 'VBAK'
      CHANGING
        ct_fieldcat      = lt_fieldcat
      EXCEPTIONS
        OTHERS           = 3.
    DATA lt_vbak TYPE TABLE OF vbak.
    SELECT * FROM vbak INTO TABLE lt_vbak UP TO 10 ROWS.
    DATA ls_layout TYPE slis_layout_alv.
    ls_layout-edit = abap_true.
    CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
      EXPORTING
        is_layout   = ls_layout
        it_fieldcat = lt_fieldcat
      TABLES
        t_outtab    = lt_vbak
      EXCEPTIONS
        OTHERS      = 2.
    
    Add comment
    10|10000 characters needed characters exceeded

  • Feb 06 at 09:29 AM

    hi

    use ref_table , ref_field of fieldcatalog in alv.

    ls_fieldcatalog-ref_table = 'vbak'.

    ls_fieldcatalog-ref_field = 'vbeln'.

    pass like above , you can get F4 help in alv output

    Add comment
    10|10000 characters needed characters exceeded

  • Feb 06 at 10:15 AM

    Just search and read online documentation on how-to Generate the Field Catalog Manually. (Here use of ref_table, ref_field is the easiest solution, as already written in the discussion you linked.)

    Hint: For OO based solution with more options, you shoud first get reference to the object behind the full screen ALV FM with FM GET_GLOBALS_FROM_SLVC_FULLSCR.

    Add comment
    10|10000 characters needed characters exceeded