‎2022 Feb 22 10:43 AM
Hello,
i am using class cl_gui_alv_grid for displaying an ALV. I have set layout parameter cwidth_opt = 'X'. So far, so good, BUT: for specific columns i want to set an fixed length, e.h. 50 for a text, field, etc... So what have i done in fieldcatalog. I set the outputlen to 50 and the field col_opt to blank.

But the result is that the field has NO length of 50 and it has column is still optimized (see yellow marked field):

Any idea for this behaviour ? 😞
br Martin
‎2022 Feb 22 8:29 PM
If you don't want to calculate automatically the width of ALL columns, I think you need to keep cwidth_opt = ' ', and set one by one col_opt = 'A' or 'X' (depends if you want to reset column width after soft refresh) for each column.