Skip to Content
0
Former Member
Aug 12, 2005 at 02:48 PM

Layout misallignment in SAPScript

15 Views

Hi,

I have written a print program for sapscript and designed a layout for it.

Three fields have been defined in the layout set.

Every time the loop runs around write_form the three field gets printed.

<b>Print program logic:</b>

loop at iresb. "IRESB is internal table.

IF IRESB-SHKZG = 'S'.

CALL FUNCTION 'WRITE_FORM'

EXPORTING

ELEMENT = 'CO-PRO' "Text Element

WINDOW = 'MAIN'.

ENDIF.

endloop.

<b>Layout logic:</b>

/E CO-PRO

A1 &IRESB-MATNR&,, ,,&IRESB-MAKTX&,, ,,&IRESB-BDMNG&

<b>Now the problem is I get output as follows:</b>

MACHINE1 CUTTING 5.000

M2 DRILLING 2.000

BIGMACHINE FITTING 7.000

<b>But I want output like:</b>

Machine1 Cutting 5.000

M2 DRILLING 2.000

BIGMACHINE FITTING 7.000

(If I keep the tab position constant then if the description of next matnr is long or short as compared to previous one the other data gets mis-alligned as you can see from the above one which I am getting)

What is solution for this ?