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

question regarding page heading...

Former Member
0 Likes
610

i think my question is simple to u,

what it actually do

report <name> LINE-SIZE 255 NO STANDARD PAGE HEADING

LINE-COUNT 065(001).

and other declaring internal table we specify header line?

please clarify this simple doubt.

thanks

1 ACCEPTED SOLUTION
Read only

RichHeilman
Developer Advocate
Developer Advocate
0 Likes
579

report <name> LINE-SIZE 255 NO STANDARD PAGE HEADING

LINE-COUNT 065(001).

This statement is defining the size of the list line and the number of lines per page. The (001) is defining that you have 1 line as the footer.

This really has nothing to do with declaring an internal table with HEADER LINE.

The extension WITH HEADER LINE, means that the internal table has a built in workarea which the read data will be inserted into. The header line has the same name as the internal table. It is suggested to no longer use HEADER LINEs when defining internal tables. You should use explicit work areas, which you can define with another DATA statement.

Data: Itab type table of ttab.
data: xtab like line of itab.

Then when you read the internal table or loop at it, you code like this.

Loop at itab into xtab.

endloop.

To write a heading in the output list,you simply use a WRITE statement in the TOP-OF-PAGE event, then when the list output reaches end of the declared LINE-COUNT, the TOP-OF-PAGE event is triggered and the report heading is written.

start-of-selection.
  
do 10 times.
  write:/ sy-index.
enddo.

Top-of-Page.
Write:/ 'This is the heading'.

Regards,

Rich Heilman

1 REPLY 1
Read only

RichHeilman
Developer Advocate
Developer Advocate
0 Likes
580

report <name> LINE-SIZE 255 NO STANDARD PAGE HEADING

LINE-COUNT 065(001).

This statement is defining the size of the list line and the number of lines per page. The (001) is defining that you have 1 line as the footer.

This really has nothing to do with declaring an internal table with HEADER LINE.

The extension WITH HEADER LINE, means that the internal table has a built in workarea which the read data will be inserted into. The header line has the same name as the internal table. It is suggested to no longer use HEADER LINEs when defining internal tables. You should use explicit work areas, which you can define with another DATA statement.

Data: Itab type table of ttab.
data: xtab like line of itab.

Then when you read the internal table or loop at it, you code like this.

Loop at itab into xtab.

endloop.

To write a heading in the output list,you simply use a WRITE statement in the TOP-OF-PAGE event, then when the list output reaches end of the declared LINE-COUNT, the TOP-OF-PAGE event is triggered and the report heading is written.

start-of-selection.
  
do 10 times.
  write:/ sy-index.
enddo.

Top-of-Page.
Write:/ 'This is the heading'.

Regards,

Rich Heilman