on 04-27-2009 4:30 PM
How can i remove the toolbar and all the functions from the re-used alv grid ?
regards
Hi,
I hope this is what you are looking for:
**make sure you create a component and get the model first
contol ALV table
data: lr_alv_usage TYPE REF TO if_wd_component_usage,
lr_if_controller TYPE REF TO iwci_salv_wd_table,
lr_config TYPE REF TO cl_salv_wd_config_table,
lr_filter TYPE REF TO if_salv_wd_std_functions.
lr_filter ?= lo_value.
set read only mode to false (and display edit toolbar)
data: lr_table_settings type ref to if_salv_wd_table_settings.
lr_table_settings ?= lo_value.
lr_table_settings->set_read_only( abap_false ).
disable insert, delete and append from the ALV toolbar
lo_value->if_salv_wd_std_functions~set_edit_append_row_allowed( abap_false ).
lo_value->if_salv_wd_std_functions~set_edit_insert_row_allowed( abap_false ).
lo_value->if_salv_wd_std_functions~set_edit_delete_row_allowed( abap_false ).
lo_value->if_salv_wd_std_functions~SET_EDIT_CHECK_AVAILABLE( abap_false ).
" Specify the setting for using ALV filter
lr_filter->set_filter_complex_allowed( value = abap_true ).
DATA: lr_table_settings TYPE REF TO if_salv_wd_table_settings.
lr_table_settings ?= lo_value.
lr_table_settings->set_enabled( abap_true ).
lr_table_settings->set_row_selectable( abap_true ).
lr_table_settings->set_design( cl_wd_table=>e_design-alternating ).
lr_table_settings->set_top_of_list_visible( abap_false ).
lr_filter->set_sort_headerclick_allowed( abap_true ).
lr_filter->aset_filter_filterline_allowed( abap_true ).
lr_filter->set_sort_complex_allowed( abap_true ).
lr_filter->set_view_list_allowed( abap_false ).
lr_filter->set_pdf_allowed( abap_true ).
Regards,
Abdul
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Check if_wd_std_functions, this has a wide range of toolbar functions. The fucntions taht you want to disable/hide just set the value as false as follows :
* disable standard fucntions
lo_value->if_salv_wd_std_functions~set_edit_check_available( abap_false ).
lo_value->if_salv_wd_std_functions~set_edit_insert_row_allowed( abap_false ).
lo_value->if_salv_wd_std_functions~set_edit_delete_row_allowed( abap_false ).
lo_value->if_salv_wd_std_functions~set_sort_headerclick_allowed( abap_false ).
lo_value->if_salv_wd_std_functions~set_sort_headerclick_allowed( abap_false ).
lo_value->if_salv_wd_std_functions~set_pdf_allowed( abap_false ).
Regards,
Radhika.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Refer SAP Online Help :
http://help.sap.com/saphelp_nw70/helpdata/EN/b5/ac884118aa1709e10000000a155106/frameset.htm
Thanx.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi,
Refer this link :
https://www.sdn.sap.com/irj/scn/wiki?path=/display/snippets/webDynproABAP-ALVControllingStandard+Buttons
I hope it helps.
Thanx.
Saurav.
Edited by: Saurav Mago on Apr 27, 2009 9:21 PM
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
86 | |
10 | |
10 | |
9 | |
6 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.