‎2008 Nov 18 12:48 PM
Hi,
i have a button in the toolbar to refresh the data.
I use
CALL METHOD GR_ALVGRID->REFRESH_TABLE_DISPLAY
EXCEPTIONS
FINISHED = 1
OTHERS = 2.
Is there a method to refresh the fieldcat?
When i press refresh i will read the actual data from database. This works!
But i update the fieldcat-table by setting 2 field with NO_OUT, but the fields
are allways shown. How can i set the output with the refreshed fieldcat.
Using ALV-OO.
Regards, Dieter
‎2008 Nov 18 12:54 PM
‎2008 Nov 18 12:51 PM
Hi Dieter,
If alvgrid is initial.
perform prepare_fieldcat using OUT....
Perform call_alv_grid_display.
else.
refresh gt_fieldcatalog.
perform prepare_fieldcat using NO_OUT....
Perform refresh_table_display.
endif.Best regards,
Prashant
‎2008 Nov 18 12:58 PM
Hi,
can you show what are you doing in
Perform call_alv_grid_display
(GR_ALVGRID->SET_TABLE_FOR_FIRST_DISPLAY??)
and
Perform refresh_table_display.
Regards, Dieter
‎2008 Nov 18 12:54 PM
‎2008 Nov 18 12:59 PM
Hi,
Try using below code.
this might help you.
rs_selfield type slis_selfield.
S_SELFIELD-REFRESH = 'X' .
This will update the processed data on screen.
Best Regards,
Deepa Kulkarni
‎2008 Nov 18 1:08 PM
Hi Dieter,
If gr_alvgrid is initial.
perform prepare_fieldcat using OUT....
Perform call_alv_grid_display. " GR_ALVGRID->SET_TABLE_FOR_FIRST_DISPLAY
else.
refresh gt_fieldcatalog.
perform prepare_fieldcat using NO_OUT....
Perform refresh_table_display. " gr_alvgrid=>refresh_table_display.
endif.Best regards,
Prashant
‎2008 Nov 18 1:15 PM
Hi,
thanks max this solved my problem.
i used:
CALL METHOD GR_ALVGRID->SET_FRONTEND_FIELDCATALOG
EXPORTING
IT_FIELDCATALOG = GT_FIELDCAT.
*
CALL METHOD GR_ALVGRID->SET_FRONTEND_LAYOUT
EXPORTING
IS_LAYOUT = GS_LAYOUT.
*
i set the layout too.
Regards, Dieter