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

printing vertical columns

Former Member
0 Kudos
224

Hi,

I am trying to print a Report. I want to print the values of the records in one row.

<b>WA : MATNR DATE COMPONENT BDMNG ENMNG

values : aaaa 1111 62 16200 16200

aaaa 1111 MM10 2707 2707

Required output.

-


62 mm10 62 mm10

-


aaaaa 11111111 16200 2707 16200 2707</b>

i get the output as it is in the work area.

How shud i go about this.

2 REPLIES 2
Read only

Former Member
0 Kudos
200

what ur doing is looping the internal table into work area. So, work area is filled with data...U might have written as write:/ wa.

Instead do this way.

write:/2 wa-matnr,

15 wa-field2,

30 wa-field3........

Position the output fields accordingly.

Read only

Former Member
0 Kudos
200

Hi,

Before starting the printing of the report arrange the data in to one internal table as per the reruirement.

data: beging of it_output occurs 0,

matnr

date

companent

bdmng

bdmng1

enmng

enmng1

....

...

end of it_output.

Loop at itab into warea.

at new matnr.

clear: counter, it_output.

it_output-matnr = wrea-matnr.

endat.

counter = counter + 1.

if counter = 1.

it_output-bdmng = warea-bdmng.

it_output-enmng = warea-enmng.

else.

it_output-bdmng1 = warea-bdmng.

it_output-enmng1 = warea-enmng.

endif.

at end of matnr.

append it_output.

endat.

endloop.

Regards,

Satya