‎2006 Jun 28 8:35 PM
I am displaying data using REUSE_ALV_GRID_DISPLAY. On the display, I would basically hide few fields(I may not always SAVE the variant), and then do some action(Like click the excel download button on the application toobar). I want a means by which the fieldcatalog can capture the hidden fields.
Ex : The Grid display has the following fields :
Plant Plant Name Material Material Desc
Now I hide, Plant name and Material Desc. If I hit the Excel download button the downloaded file should basically look as below :
Plant Material
FYI. For some client specific requirements, I am having to use my own excel download.
Any help in this regard is highly appreciated.
‎2006 Jun 28 8:37 PM
Have you tried hiding and downloading, it should work I guess.
Regds
Manohar
‎2006 Jun 28 9:43 PM
I am not using the ALV default download functionality. I am giving a custome button for excel download and then downloading using say WS_DOWNLOAD
‎2006 Jun 28 9:58 PM
You cannot do that because in your custom function, you are using the same original internal table to download and that will have all the four columns. Standard functionality will allow you to download the displayed columns.
One possible option is to use REUSE_ALV_LIST_LAYOUT_INFO_GET to get the current ALV settings and then create a dynamic internal table with the columns that are not hidden and then download it. Search the forum for dynamic internal table and you will see a lot of examples.