2010 Feb 24 5:39 AM
Hi,
I'm using CL_GUI_ALV_GRID-SET_TABLE_FOR_FIRST_DISPLAY to display the list. I have 2 questions
1. Is it possible to provide the user an option to enter the number of rows that needs to be printed per page? Is there any standard object available to do this?
2. There is an option to restrict the number of lines per page when the user clicks on the standard print button available on the ALV toolbar. (Print -> Properties -> General Properties -> Format -> Rows). Is it possible to set this value programmatically?
Thanks,
Raj.
2010 Feb 24 5:55 AM
Hi,
As such alv display has standard buttons for changing the layout on the tool bar.
You can programatically change this , you can set the layout, there is one structure in layout.
You can check out "slis_layout_alv"
Also check out for printing settings :
"slis_print_alv0" and "slis_print_alv1" there are fields in this that can help in your scenario.
Its up to you how you use them.
Regards,
Salil.
2010 Feb 24 6:30 AM
Hello Raj,
In the method SET_TABLE_FOR_FIRST_DISPLAY you have a param IS_PRINT (structure LVC_S_PRNT).
LVC_S_PRNT is a deep structure containing another structure ALV_S_PCTL (deep structure with PRI_PARAMS & ARC_PARAMS).
You can use the PRI_PARAMS to fit your requirement.
BR,
Suhas