cancel
Showing results for 
Search instead for 
Did you mean: 

ALV Grid expansion

Former Member
0 Kudos

Hi Experts

Could anyone tell me how can I keep the ALV report column statble it will expand the columns whenever I am opening the report. Everytime I have to unfreez and save it.

Monto

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Everyone

I am closing this thread for date, I got it after defining sy-datum

Thanks

Monto

Former Member
0 Kudos

Hi Monto,

You can set the output length of column based on the field 'outputlen' of fieldcatlog.

Regards,

Atish

Former Member
0 Kudos

Hello Atish

Thanks for your advice , seeing below can you tell me where to define the column length

Eg:

clear st_fieldcat.

add 1 to lva_col_pos.

st_fieldcat-tabname = 'PA_IT_single.

st_fieldcat-fieldname = 'VALUE_NEW'.

st_fieldcat-ref_tabname = 'CDPOS'.

st_fieldcat-ref_fieldname = 'VALUE_NEW'.

st_fieldcat-row_pos = '7'.

st_fieldcat-col_pos = lva_col_pos.

append st_fieldcat to pa_it_fieldcat.

clear st_fieldcat.

add 1 to lva_col_pos.

st_fieldcat-tabname = PA_IT_single'.

st_fieldcat-fieldname = 'VALUE_OLD'.

st_fieldcat-ref_tabname = 'CDPOS'.

st_fieldcat-ref_fieldname = 'VALUE_OLD'.

st_fieldcat-row_pos = '8'.

st_fieldcat-col_pos = lva_col_pos.

append st_fieldcat to pa_it_fieldcat.

Monto

Former Member
0 Kudos

Hi Monto,

Use it as

st_fieldcat-outputlen = <desired length>.

Regards,

Atish

Former Member
0 Kudos

Hello Atish

Thanks for your help once again, some time in my value new it is displayin a date format as 01012007 instead of 01/10/2007 how can change it

clear st_fieldcat.

add 1 to lva_col_pos.

st_fieldcat-tabname = 'PA_IT_single.

st_fieldcat-fieldname = 'VALUE_NEW'.

st_fieldcat-ref_tabname = 'CDPOS'.

st_fieldcat-ref_fieldname = 'VALUE_NEW'.

st_fieldcat-row_pos = '7'.

st_fieldcat-col_pos = lva_col_pos.

append st_fieldcat to pa_it_fieldcat.

Thanks

Former Member
0 Kudos

Hi,

Can you show the code where you are assigning value for date.

Regards,

Atish

Former Member
0 Kudos

Hi,

Please make sure that the field which you keep the day is the same as the format of SY-DATUM, and do not set its output length equal to 8.

Regards.