06-02-2011 8:09 AM
Hi,
i am using ALV_LIST_DISPLAY FM for my report , it's working fine
the output is 10 columns, there is no hide options for when i right click on Column, pls help me
how to Hide the Column in display screen , but it's possible for ALV_GRID_DISPLAY FM
Regards
Mani
06-02-2011 8:25 AM
hi
If you want to hide a column you can use fieldcatalog and pass this fieldcatalog as exporting parameter
DATA: LS_FIELDCAT TYPE SLIS_FIELDCAT_ALV,
LT_FIELDCAT TYPE SLIS_T_FIELDCAT_ALV.
CLEAR LS_FIELDCAT.
LS_FIELDCAT-FIELDNAME = 'ZZV_CATEGORY'.
LS_FIELDCAT-NO_OUT = 'X'.
LS_FIELDCAT-tech = 'X'.
LS_FIELDCAT-SP_GROUP = 'A'.
LS_FIELDCAT-NO_SUM = 'X'.
APPEND LS_FIELDCAT TO LT_FIELDCAT.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
I_INTERFACE_CHECK = ' '
I_STRUCTURE_NAME = 'zvehiclein01'
IT_FIELDCAT = lt_fieldcat
I_SAVE = ' '
TABLES
t_outtab = tab
EXCEPTIONS
PROGRAM_ERROR = 1
OTHERS = 2 .
06-02-2011 8:25 AM
hi
If you want to hide a column you can use fieldcatalog and pass this fieldcatalog as exporting parameter
DATA: LS_FIELDCAT TYPE SLIS_FIELDCAT_ALV,
LT_FIELDCAT TYPE SLIS_T_FIELDCAT_ALV.
CLEAR LS_FIELDCAT.
LS_FIELDCAT-FIELDNAME = 'ZZV_CATEGORY'.
LS_FIELDCAT-NO_OUT = 'X'.
LS_FIELDCAT-tech = 'X'.
LS_FIELDCAT-SP_GROUP = 'A'.
LS_FIELDCAT-NO_SUM = 'X'.
APPEND LS_FIELDCAT TO LT_FIELDCAT.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
I_INTERFACE_CHECK = ' '
I_STRUCTURE_NAME = 'zvehiclein01'
IT_FIELDCAT = lt_fieldcat
I_SAVE = ' '
TABLES
t_outtab = tab
EXCEPTIONS
PROGRAM_ERROR = 1
OTHERS = 2 .
06-02-2011 9:36 AM
Dear Akanksha
Thanks
Yes Your answer is Correct, but i need after Displaying Report there i need to hide the column
eg:- if we use FM (for ALV_GRID_DISPLAY ) to display the report there you right click on the column we get Hide options,
i need same in LIST DISPLAY
Regards
mani