Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Hide a column in ALV(FPM)

Hi All,

I'm trying to hide a column in portal output in the item table.

REQ: need to hide retunrs tab in the ouput alv.

Component: WDC_WSGM_GR

Process I have done: 

Enhanced the wddoinit method in the component controller and in the post exit, im writing the following code,

method _PST_00O2TMTHKRNTPMP8KOGJNEY56 . "Exit of WDDOINIT (in ZCI_HIDE_RETURNS_ITEM )

* Declare ALV config table

   data: ALV_CONFIG_TABLE  type REF TO CL_SALV_WD_CONFIG_TABLE.

   DATA: wd_table TYPE REF TO iwci_salv_wd_table.

   DATA: wd_table_usage TYPE REF TO if_wd_component_usage.

   DATA: column_settings TYPE REF TO if_salv_wd_column_settings,

         column          TYPE REF TO cl_salv_wd_column.

   wd_table_usage = wd_this->wd_cpuse_cus_gr_item_table( ).

   IF wd_table_usage->has_active_component( ) IS INITIAL.

     wd_table_usage->create_component( ).

   ENDIF.

   wd_table = wd_this->wd_cpifc_cus_gr_item_table( ).

   alv_config_table = wd_table->get_model( ).

   column_settings ?= alv_config_table.

   column = column_settings->get_column( 'RETURN_ITEM' ).

   column->set_visible( if_wdl_core=>visibility_none ).

endmethod.


The column visibility is being changed to 01 but still im able to see the return item in the output.


Please provide your suggestions



Former Member
Former Member replied

It is working now.

After the code in the method wddoinit, the logic is being overridden in another method OVERRIDE_EVENT_OIF. Therefore i have implemented similar code there in the post exit and its working fine now.

Thanks,

Vishwak

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question