ALV - REF_FIELDNAME & REF_TABNAME in Fieldcat

Question: Hi,
To filter the VBELN, I have given -
S_FIELDCAT-REF_FIELDNAME = 'VBELN'.
S_FIELDCAT-REF_TABNAME = 'VBAK'.

this is filtering the records but deleting the leading zeros e.g
SO NO 0000000032 is shown as 32.

How to show the whole number 0000000032 ?

Kindly assist.

Thanks,
MRCABAP

Answer:
Hi,
When we display ALV, there is one FILTER button on the application tool bar.
I tried to use on VBELN, but if I give the whole number 0000000032, then only it will filter and will show that record, if I give only 32, it will show blank.

So I made the following changes in the fieldcat for VBELN –

this is filtering the records but deleting the leading zeros e.g
SO NO 0000000032 is shown as 32, even in the basic ALV list (without filtering).

How to show the whole number like 0000000032 ?

Kindly assist.

Thanks,
MRCABAP

Answer:
Maybe you can set

S_FIELDCAT-lzero = space .

or

S_FIELDCAT-no_convext = 'X' .

good luck ...

Answer:
Thanks for the reply but S_FIELDCAT-lzero is only for NUMC data type fields and S_FIELDCAT-no_convext also doesnt work.

Kindly assist.

Thanks,
MRCABAP
Copyright ?2007 - 2008 www.jt77.com