on 10-10-2018 7:59 AM
I have passed the variant gs_variant to the method set_table_for_first_display of cl_gui_alv_grid for initial display of editable ALV.
When I refresh the ALV using the method refresh_table_display after editing contents of ALV , all the settings of the layout variant are lost eventhough the gs_variant has the correct variant set.
CALL METHOD g_grid->set_table_for_first_display
EXPORTING
is_layout = gs_layout
is_variant = gs_variant
i_save = 'A'
i_default = 'X'
it_toolbar_excluding = gt_exclude
CHANGING
it_fieldcatalog = gt_fieldcat
it_outtab = gt_outtab.
I have tried using methods get_variant, set_variant but nothing seems to work out.
CALL METHOD g_grid->get_variant IMPORTING es_variant = gs_variant.
CALL METHOD g_grid->set_variant EXPORTING is_variant = gs_variant.
CALL METHOD cl_gui_cfw=>flush.
CALL METHOD g_grid->set_frontend_layout EXPORTING is_layout = gs_layout.
CALL METHOD g_grid->refresh_table_display.
Can someone please guide me how to save the current layout varaint settings when Refreshing the ALV .
Thank you for you inputs Bongkeun Shin . I have tried this, but this did not solve my issue.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I have the same issue. Does anyone know a solution?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
When I refresh the ALV, I only use 2 methods below.
I recommend you to use only 2 methods and check out if there is any code that refresh gs_layout.
CALL METHOD po_grid->refresh_table_display
CALL METHOD cl_gui_cfw=>flush
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
81 | |
25 | |
12 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.