cancel
Showing results for 
Search instead for 
Did you mean: 

How to hide default buttons on WD selection screen

Former Member
0 Kudos

Hi Experts,

Is there a way to hide default buttons ( Cancel, Check, Reset, Copy ) on web dynpro selection screen ??

Please let me know how can I achieve this..

Thanks in advance !

Anand

Accepted Solutions (1)

Accepted Solutions (1)

thomas_jung
Developer Advocate
Developer Advocate

By selection screen do you mean the select-options reusable component? If so, then there is an API of the component that you can call to disable these fields. Use the SET_GLOBAL_OPTIONS method of the select-options API to acomplish this:

data: l_ref_cmp_usage type ref to if_wd_component_usage.
  l_ref_cmp_usage =   wd_this->wd_cpuse_select_options( ).
  if l_ref_cmp_usage->has_active_component( ) is initial.
    l_ref_cmp_usage->create_component( ).
  endif.
  wd_this->lv_wd_select_options =
       wd_this->wd_cpifc_select_options( ).
* init the select screen
  wd_this->lv_sel_handler =
       wd_this->lv_wd_select_options->init_selection_screen( ).
....

  wd_this->lv_sel_handler->set_global_options(
    EXPORTING
*      i_display_btn_cancel  = ABAP_TRUE    " Displays "Cancel" Button
*      i_display_btn_check   = ABAP_TRUE    " Displays "Check" Button
*      i_display_btn_reset   = ABAP_TRUE    " Displays "Reset" Button
      i_display_btn_execute = abap_false    " Displays "Apply" Button
  ).

Former Member
0 Kudos

Hi Thomas,

Got it !!

Thanks a lot for super quick reply..

Anand

Answers (0)