The column text may change upon the horizontal resizing of a column. There are three methods to accomplish this:
Method Name | Maximum Length of Heading |
---|---|
set_short_text | 10 |
set_medium_text | 20 |
set_long_text | 40 |
The following example shows usage of all three. A column
object is declared and instantiated as a reference to the result of alv->get_columns( )->get_column( 'DISTID' )
. The column name must be in all capital letters. This is so that this method chaining is only called once in its instantiation, instead of being executed every time a column heading is changed.
DATA column TYPE REF TO cl_salv_column.
column = alv->get_columns( )->get_column( 'DISTID' ).
column->set_short_text( 'Dist. Unit' ).
column->set_medium_text( 'Unit of Distance' ).
column->set_long_text( 'Mass Unit of Distance (kms, miles)' ).