08-25-2006 2:58 PM
Hi ABAPer's
Is it possible to Change the Line-count of a page Dynamically.
My req is I want to Change the Line-count of the page inside the program based on the option selected.For eg if option is 1 page-count should be 64 else it should be 65.
How to do this.Kindly Calrify.
Rgds
Sapient
08-25-2006 3:03 PM
Hi,
You can change the line count just by specifing this statement. Check this sample program.
new-page line-count 20.
REPORT ZRICHA_001 line-count 4.
data : v_code type sy-ucomm.
start-of-selection.
v_code = '1'.
do 4 times.
case v_code.
when '1'.
new-page line-count 20.
write : / 'a'.
v_code = '2'.
when '2'.
new-page line-count 40.
write : / 'b'.
v_code = '3'.
when '3'.
new-page line-count 60.
write : / 'c'.
endcase.
enddo.
Regards,
Richa
08-25-2006 2:59 PM
use the syntax.
if cond.
new-page line-count 64.
else.
new-page line-count 65.
endif
see sample prog:
DEMO_LIST_LINE_COUNT
08-25-2006 3:03 PM
Hi,
You can change the line count just by specifing this statement. Check this sample program.
new-page line-count 20.
REPORT ZRICHA_001 line-count 4.
data : v_code type sy-ucomm.
start-of-selection.
v_code = '1'.
do 4 times.
case v_code.
when '1'.
new-page line-count 20.
write : / 'a'.
v_code = '2'.
when '2'.
new-page line-count 40.
write : / 'b'.
v_code = '3'.
when '3'.
new-page line-count 60.
write : / 'c'.
endcase.
enddo.
Regards,
Richa