Skip to Content
0
Former Member
Apr 22, 2008 at 10:04 PM

ECC6 - Refresh ALV grid

12 Views

Hi experts,

I have a dialog screen that will display a report in an ALV grid. I don't know what is wrong with my code. The ALV grid is not refreshed if I back out from the screen and go back in for the new data. It is displaying the data from the previous run. Please see code below.

Thanks,

Chuong

*** BEFORE THE ALV IS DISPLAYED ****

* create object
   CREATE OBJECT cust_contain_mass_ch_parm11
      EXPORTING container_name = 'CONTAINER_ALL'.

* create ALV grid
   CREATE OBJECT grid_mass_ch_parm11
        EXPORTING
          i_parent = cust_contain_mass_ch_parm11.


* Load data into the grid and display them
   CALL METHOD grid_mass_ch_parm11->set_table_for_first_display
    EXPORTING
              is_layout            = gs_layout_mass_ch
              it_toolbar_excluding = lt_exclude_mass_ch
    CHANGING  it_outtab            = itab_mass_ch
              it_fieldcatalog      = parm_fieldcat[] .


*** AFTER THE ALV IS DISPLAYED ****

       CALL METHOD cust_contain_mass_ch_parm11->free.
       CALL METHOD cl_gui_cfw=>flush.

Code Formatted by: Alvaro Tejada Galindo on Apr 22, 2008 6:07 PM