2009 Jul 27 7:52 AM
HI Experts,
I have displayed ALV Grid using CL_GUI_ALV_GRID=>SET_TABLE_FOR_DISPLAY.
I want to decrease the row height and width.
Can any one suggest how to do this?
Regards,
Kumar.
2009 Jul 27 8:48 AM
Hi Kumar,
Row height it predefined and you won't change it, but you can adjust column width.
For that use field COL_OPT of layout structure ( type LVC_SLAYO ) to optimize all columns width, or set explicit width using field catalog, setting field OUTPUTLEN for certain column.
Regards
Marcin
Hi Kumar,
Row height it predefined and you won't change it, but you can adjust column width.
For that use field COL_OPT of layout structure ( type LVC_SLAYO ) to optimize all columns width, or set explicit width using field catalog, setting field OUTPUTLEN for certain column.
Regards
Marcin
2009 Jul 27 8:48 AM
Hi Kumar,
Row height it predefined and you won't change it, but you can adjust column width.
For that use field COL_OPT of layout structure ( type LVC_SLAYO ) to optimize all columns width, or set explicit width using field catalog, setting field OUTPUTLEN for certain column.
Regards
Marcin
2009 Jul 30 7:34 AM
Hi..
Thank You for your answer.
I am able to decrease width upto one character space. Any apossibilities to decrease furthur.
And any other way to decrease to Row Height.
Thanks & Regards,
Kumar
2009 Jul 30 10:31 AM
Hai,
There's a method called SET_RESIZE_ROWS in the class CL_GUI_ALV_GRID, which is a protected one. So create a subclass of CL_GUI_ALV_GRID and then access this method. Give it a try.
Best Regards,
rama
2009 Aug 31 7:31 AM
Hi,
SET_RESIZE_ROWS is protected method,
I am unable to use.
Thanks,
Kumar.
2009 Dec 29 9:53 AM
Hi, newtoAbap
Can you explain in more datail how to use method SET_RESIZE_ROWS ?
Thanks.
Edited by: Gabtia on Dec 29, 2009 10:56 AM
2010 Oct 15 2:21 PM
In my case I did not want to display the whole textfield content, only the beginning.
When trying to restrict output length of a cell i found out that:
cwidth_opt ALV setting (e.g. ls_layout-cwidth_opt = 'X'.) overrules
outputlen setting on cell level (e.g. <fieldcat>-outputlen = 10.)
| User | Count |
|---|---|
| 6 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |