Columns

Depending on how you got the ALV configuration model, there is either just one, identically named column object for each attribute of your context node, or there is no column object at all (see Getting the ALV Configuration Model). In the latter case, you must generate the column objects required for the desired display of the ALV output separately.

You can make the following settings for column objects:

  • Get column object

  • Get the technical name of a column

  • Create and delete column objects

  • Set up a column header (see Column Headers)

  • Change the position of a column (see Position of Columns)

More Information

Get column object

In order to make the required settings for a column, you first have to get the instance of the column. You can decide whether you address a specific column object by its name or get all column objects at once in order to handle them one after another. In both cases you use the methods of the interface class IF_SALV_WD_COLUMN_SETTINGS for this (implementing class CL_SALV_WD_CONFIG_TABLE).

Function

Method

Get individual column object

GET_COLUMN

Get all column objects

GET_COLUMNS

Get the technical name of a column

Use class CL_SALV_WD_COLUMN to get the name of the current column instance.

Function

Method

Get technical column name

GET_ID

Create and delete column objects

If, when getting the ALV configuration model, you defined that the system should not generate column objects, you need to generate the column objects required for displaying the ALV data yourself in your application.

All columns for which a column object exists are displayed to the user in a column set. If you do not want a column to be displayed to a user, you have to delete the corresponding column object.

To generate or delete a column object, use the methods of the interface class IF_SALV_WD_COLUMN_SETTINGS (implementing class CL_SALV_WD_CONFIG_TABLE).

Function

Method

Create column object

CREATE_COLUMN

Delete column object

DELETE_COLUMN

Delete all column objects

DELETE_COLUMNS