Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

column width in ALV

Former Member
0 Likes
813

hi,

is there a way to fix the width of the colums of alv even while displaying vertical seperators.

Regards,

Tarun Bahal

5 REPLIES 5
Read only

Former Member
0 Likes
775

Pass

 is_layout-colwidth_optimize = 'X'. 

This will allow the ALV to display each column to the max width of data for each column.

Hope this helps.

Thanks,

Balaji

Read only

Former Member
0 Likes
775

Hi,

Please refer to the code below:


  gs_fieldcat-fieldname = 'BLART'.
*  gs_fieldcat-coltext   = 'Doc type'.
  gs_fieldcat-seltext_s = 'Doc type'.
  gs_fieldcat-seltext_l = 'Doc type'.
  gs_fieldcat-seltext_m = 'Doc type'.
  gs_fieldcat-fix_column  = 'X'.
  gs_fieldcat-outputlen = '4'.
  gs_fieldcat-tabname = 'GT_OUTPUT'.
  APPEND gs_fieldcat TO gt_fieldcat.

Thanks,

Sriram Ponna.

Read only

Former Member
0 Likes
775

hi ,

use like this for restricting the output length,

fieldcatalog-outputlen = 7 like..

and it is always better to use the like this i think..

fieldcat-reptext_ddic = 'Material no'.

regards,

venkat.

Read only

0 Likes
775

width can stikl be changed by used even if i use fix_column

Regards

Read only

0 Likes
775

hi,

ya its not possible to freeze column width.....