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

Fields Length

Former Member
0 Likes
664

Hi,

I have pulled up the required e-mail field from table ADR6 , but the problem is the ADR6-SMTP_ADDR field length is 241 char which is taking too much space in the ALV output may i know how to reduce the actual legnth of field to the required pls..

Thxs,

Vin.

3 REPLIES 3
Read only

Former Member
0 Likes
545

hi

check the below links may be useful for u

Regards,

Naveen

Read only

0 Likes
545

While filling the field catalog fill the field "Outputlength"

Message was edited by: Abhishek Jolly

Read only

Laxmana_Appana_
Active Contributor
0 Likes
545

Hi,

if you are using 'REUSE_ALV_FIELDCATALOG_MERGE' to build the field catelog, then change the field length with below code :

loop at it_fieldcat into x_fieldcat.
 if x_fieldcat-fieldname = 'SMTP_ADDR'.
   x_fieldcat-OUTPUTLEN  = 20.
    modify it_fieldcat from x_fieldcat index sy-tabix.
   endif.
endloop.

if you are building the fieldcatelog in your own way then use below code to change the field length.

it_fieldcat-FIELDNAME = 'SMTP_ADDR'.

it_fieldcat-KEY = 'X'.

it_fieldcat-OUTPUTLEN = '20'.

it_fieldcat-SELTEXT_L = 'E-Mail'.

APPEND it_fieldcat .

CLEAR it_fieldcat .

Regards

Appana

*Reward Points for useful answers