2013 Dec 16 10:25 AM
Hi I am using method object-> set_table_for_first_display to display report out in the form of grid. When i add new field to the output, they are adding successfully but it going to store in column set, not in displayed column. to get them to display i have to go to choose layout->change layout->drag them to displayed column area.
How can i get them to displayed column area automatically so that i can see them in report out put.
please let me know if you not clear about my question.
thanks,
2013 Dec 16 11:57 AM
There can be 2 possible reasons
(1) Existing Global/User layout Settings .If a layout is already saved by ticking the 'Default Layout settings' and set as global/user specific ( I_SAVE = 'A'/'U'/'X' in the method set table for first display) ,then the layout maybe applied everytime the ALV is executed.In such a case the current layout needs to be deleted and after the new fields are added,they can be set again
(2)Field length of the catalog..I am not sure of the total length but there is a restriction on the number of fields displayed(based on the total length of the fields involved,I guess).
So either by setting a global variant as default or choosing specific fields in the catalog the new layout can be obtained.
Hope it helps.
Hi I am using method object-> set_table_for_first_display to display report out in the form of grid. When i add new field to the output, they are adding successfully but it going to store in column set, not in displayed column. to get them to display i have to go to choose layout->change layout->drag them to displayed column area.
How can i get them to displayed column area automatically so that i can see them in report out put.
please let me know if you not clear about my question.
thanks,
2013 Dec 16 10:41 AM
Hi, you can try to refresh your table display using this code:
DATA: gr_alv TYPE REF TO cl_gui_alv_grid.
gr_alv->refresh_table_display( ).
Regards,
2013 Dec 16 10:54 AM
Hi ,
It is all depends on the field catalog settings.
Look for "An Easy Reference for ALV Grid Control.pdf"
There is a chapter "Changing Field Catalog or Layout after First Display"
Also see program BCALV_FIELDCAT_TEST
Regards.
2013 Dec 16 11:20 AM
When you added the new field to the field catalog, make sure, the no_out attribute is set to space.
2013 Dec 16 11:31 AM
Hi Eitan,
I did not find any clue from example program.
Thanks
2013 Dec 16 11:33 AM
Hi Susmitha,
I have not used no_out parameter in field catalog ...
Thanks
2013 Dec 16 11:44 AM
Can you please attach screen shot for the same..? Have you created in any groups for output ALV or they were already their... ?
Nabheet
2013 Dec 16 11:57 AM
There can be 2 possible reasons
(1) Existing Global/User layout Settings .If a layout is already saved by ticking the 'Default Layout settings' and set as global/user specific ( I_SAVE = 'A'/'U'/'X' in the method set table for first display) ,then the layout maybe applied everytime the ALV is executed.In such a case the current layout needs to be deleted and after the new fields are added,they can be set again
(2)Field length of the catalog..I am not sure of the total length but there is a restriction on the number of fields displayed(based on the total length of the fields involved,I guess).
So either by setting a global variant as default or choosing specific fields in the catalog the new layout can be obtained.
Hope it helps.
| User | Count |
|---|---|
| 3 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |