We can do any number of modification to the fieldcatalog and layout of ALV grid even after it has been displayed on the screen, we can hide certain columns , change the column text, change the column position etc. We can achieve all this simply by using the following methods of the class CL_GUI_ALV_GRID:
For fieldcatalog modification:
get_frontend_fieldcatalog
set_frontend_fieldcatalog
For layout modification:
get_frontend_layout
set_frontend_layout
Steps to change the fieldcatalog after first display:
The ALV layout can be changed in a similar manner using the get and set methods meant for layout.
Example:
This is the initial display of ALV gird.
On clicking the button Technical Name the existing column headings will be replaced by their equivalent technical name.
On clicking the Layout 1 button the existing layout will be changed to Zebra layout.
Similarly you can present multiple layout and display options to the user using this technique.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
4 | |
3 | |
2 | |
2 | |
2 | |
2 | |
1 | |
1 | |
1 | |
1 |