Skip to Content
avatar image
Former Member

ALV and optimazation of cells

Hi,

i have a problem with an OO ALV grid.

I set the field cwidth_opt in layout to 'X'. the result is that i get the columns optimized by the content(!) of the column.

my problem: e.g. i have a 2 char column. the header of this column e.g. is "XXXXXXXXXXX" -> much more longer then the content.

how can i optimize the columns by header of column and not by it's content ?

br Martin

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Best Answer
    Apr 19, 2017 at 10:39 AM

    Hi,

    assign parameters as :

    layout-colwidth_optimize = 'X'. (type : slis_layout_alv)

    and fieldcatalog-ddictxt = 'L'. then modify fieldcatalog (type : slis_t_fieldcat_alv)

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Apr 19, 2017 at 11:39 AM

    Hi,

    thank you very much !

    the field ddictxt does NOT exist -> but there is a field colddictxt -> setting this to 'L' and it works perfect :)

    br, Martin

    Add comment
    10|10000 characters needed characters exceeded