<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: ALV grid - Disabling options in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-grid-disabling-options/m-p/6127777#M1364848</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For this kind of a requirement where you want the standard ALV&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;pf-status&lt;/STRONG&gt; to get modified, you have to exclude the required &lt;STRONG&gt;Send Option&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;functionality from it. You can do like:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;

DATA: itab_exclude TYPE slis_t_extab,
      wa_exclude TYPE slis_extab.

*&amp;amp;---------------------------------------------------------------------*

*&amp;amp; *MAINTAINIG INTERNAL TABLE FOR EXCLUDING COMPONENTS FROM THE ALV STANDARD TOOLBAR
* For excluding the components from the standard toolbar we have to comment the
*  i_callback_pf_status_set          = 'PF_STATUS' in the grid display function module
*&amp;amp;---------------------------------------------------------------------*

  wa_exclude-fcode = '&amp;amp;LFO'.

  APPEND wa_exclude TO itab_exclude.

  CLEAR wa_exclude.

  wa_exclude-fcode = '&amp;amp;NFO'.

  APPEND wa_exclude TO itab_exclude.  "You can like this exclude the function code of send Option functionality here


Then you can pass it in the Reuse Function Module,

  CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
   EXPORTING
*    I_INTERFACE_CHECK                 = ' '
*    I_BYPASSING_BUFFER                = ' '
*    I_BUFFER_ACTIVE                   = ' '
      i_callback_program                = sy-repid
      i_callback_pf_status_set          = 'PF_STATUS'
      i_callback_user_command           = 'COMM'
      i_callback_top_of_page            = 'TOP'
*    I_CALLBACK_HTML_TOP_OF_PAGE       = ' '
*    I_CALLBACK_HTML_END_OF_LIST       = ' '
*    I_STRUCTURE_NAME                  =
*    I_BACKGROUND_ID                   = ' '
      i_grid_title                      = it_grid_title
*    I_GRID_SETTINGS                   =
      is_layout                         = it_layout
      it_fieldcat                       = it_field
*    it_excluding                      = itab_exclude      " function codes appended in this internal table will get deleted in o/p

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope it helps,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mansi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 26 Aug 2009 05:21:11 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2009-08-26T05:21:11Z</dc:date>
    <item>
      <title>ALV grid - Disabling options</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-grid-disabling-options/m-p/6127776#M1364847</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a question on the ALV grid.&lt;/P&gt;&lt;P&gt;In the ALV grid, there is the button - EXPORT under which the following options are available:-&lt;/P&gt;&lt;P&gt;- Spreadsheet&lt;/P&gt;&lt;P&gt;- Word Processing&lt;/P&gt;&lt;P&gt;- Local File&lt;/P&gt;&lt;P&gt;- Send...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I just want to whether it is possible to remove the 'Send' option from the list, all other options should be available ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Ajit G&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 26 Aug 2009 05:04:15 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-grid-disabling-options/m-p/6127776#M1364847</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-08-26T05:04:15Z</dc:date>
    </item>
    <item>
      <title>Re: ALV grid - Disabling options</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-grid-disabling-options/m-p/6127777#M1364848</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For this kind of a requirement where you want the standard ALV&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;pf-status&lt;/STRONG&gt; to get modified, you have to exclude the required &lt;STRONG&gt;Send Option&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;functionality from it. You can do like:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;

DATA: itab_exclude TYPE slis_t_extab,
      wa_exclude TYPE slis_extab.

*&amp;amp;---------------------------------------------------------------------*

*&amp;amp; *MAINTAINIG INTERNAL TABLE FOR EXCLUDING COMPONENTS FROM THE ALV STANDARD TOOLBAR
* For excluding the components from the standard toolbar we have to comment the
*  i_callback_pf_status_set          = 'PF_STATUS' in the grid display function module
*&amp;amp;---------------------------------------------------------------------*

  wa_exclude-fcode = '&amp;amp;LFO'.

  APPEND wa_exclude TO itab_exclude.

  CLEAR wa_exclude.

  wa_exclude-fcode = '&amp;amp;NFO'.

  APPEND wa_exclude TO itab_exclude.  "You can like this exclude the function code of send Option functionality here


Then you can pass it in the Reuse Function Module,

  CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
   EXPORTING
*    I_INTERFACE_CHECK                 = ' '
*    I_BYPASSING_BUFFER                = ' '
*    I_BUFFER_ACTIVE                   = ' '
      i_callback_program                = sy-repid
      i_callback_pf_status_set          = 'PF_STATUS'
      i_callback_user_command           = 'COMM'
      i_callback_top_of_page            = 'TOP'
*    I_CALLBACK_HTML_TOP_OF_PAGE       = ' '
*    I_CALLBACK_HTML_END_OF_LIST       = ' '
*    I_STRUCTURE_NAME                  =
*    I_BACKGROUND_ID                   = ' '
      i_grid_title                      = it_grid_title
*    I_GRID_SETTINGS                   =
      is_layout                         = it_layout
      it_fieldcat                       = it_field
*    it_excluding                      = itab_exclude      " function codes appended in this internal table will get deleted in o/p

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope it helps,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Mansi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 26 Aug 2009 05:21:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-grid-disabling-options/m-p/6127777#M1364848</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-08-26T05:21:11Z</dc:date>
    </item>
    <item>
      <title>Re: ALV grid - Disabling options</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/alv-grid-disabling-options/m-p/6127778#M1364849</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Agit G,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To disable options in ALV; you got to call following method in PBO,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
  ******************Hiding Buttons*****************
  ls_exclude = cl_gui_alv_grid=&amp;gt;mc_fc_sum.
  APPEND ls_exclude TO lt_exclude.
  CLEAR ls_exclude.
  ls_exclude = cl_gui_alv_grid=&amp;gt;mc_mb_filter.
  APPEND ls_exclude TO lt_exclude.

  CLEAR ls_exclude.
  ls_exclude = cl_gui_alv_grid=&amp;gt;mc_mb_sum.
  APPEND ls_exclude TO lt_exclude.

*lt_exclude contains all set of filters that have to be disabled.

*  IF w_check = space.

  CALL METHOD t_grid-&amp;gt;set_table_for_first_display
    EXPORTING
*    i_buffer_active               =
*    i_bypassing_buffer            =
*    i_consistency_check           =
*      i_structure_name              = 'T_TABLE'
*    is_variant                    =
*    i_save                        =
*    i_default                     = 'X'
      is_layout                     = w_layo
*    is_print                      =
*    it_special_groups             =
     it_toolbar_excluding          = lt_exclude
*    it_hyperlink                  =
*    it_alv_graphics               =
*    it_except_qinfo               =
*    ir_salv_adapter               =
    CHANGING
      it_outtab                     = t_spfli
      it_fieldcatalog               = t_fcat
    it_sort                       = t_sort
*    it_filter                     =
*  EXCEPTIONS
*    invalid_parameter_combination = 1
*    program_error                 = 2
*    too_many_lines                = 3
*    others                        = 4
          .
  IF sy-subrc &amp;lt;&amp;gt; 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
*            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
  ENDIF.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I hope that is going to help you.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Zahack&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 26 Aug 2009 05:53:35 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/alv-grid-disabling-options/m-p/6127778#M1364849</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-08-26T05:53:35Z</dc:date>
    </item>
  </channel>
</rss>

