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

Conversion exit..

Former Member
0 Likes
1,274

Hi guyz..!

In a report of i need to modify .. one of the data output type..

right now its (say GL acc HKONT) coming 589040 ..but it

should come out as 0000589040 ..with leading zeros..!

how do i do it with conv exits...?

please help.

2 REPLIES 2
Read only

Former Member
0 Likes
720

Hi Jaif,

You can use CONVERSION_EXIT_ALHA_INPUT.

In the export part send your variable & the import part you'll get the desired output. Declare the import variable of the length that you want as output.

Reward all helpful answers.

Regards,

Siddhesh sanghvi.

Read only

Former Member
0 Likes
720

Hi Jaif,

Use CONVERSION_EXIT_ALPHA_INPUT function module to convert from external to internal format.

Check this code.

DATA: V_HKONT(10).

LOOP AT ITAB.

CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'

EXPORTING

INPUT = ITAB-HKONT

IMPORTING

OUTPUT = V_HKONT.

WRITE:/ V_HKONT.

ENDLOOP.

Otherwise, Simply declare a variable of type N with 10 length.

DATA V_HKONT(10) TYPE N.

LOOP AT ITAB.

V_HKONT = ITAB-HKONT.

WRITE:/ V_HKONT.

ENDLOOP.

Thanks,

Vinay