09-16-2008 12:19 AM
Hello,
I have created one container and producing ALV Grid output on a modal dialog screen. i do not want the ALV Toolbar to appear on this screen. How can I hide it ?
ALso I need to hide some buttons on a Text edit control. How can I hide them ?
Thanks and rgds,
Anand
09-16-2008 4:05 AM
Hi,
To exclude some Toolbar functions, please do the below
DATA:
lt_toolbar_excl TYPE ui_functions.
Exclude Some toolbar functions
APPEND cl_gui_alv_grid=>mc_fc_detail TO lt_toolbar_excl.
APPEND cl_gui_alv_grid=>mc_fc_info TO lt_toolbar_excl.
APPEND cl_gui_alv_grid=>mc_fc_graph TO lt_toolbar_excl.
APPEND cl_gui_alv_grid=>mc_fc_view_crystal TO lt_toolbar_excl.
APPEND cl_gui_alv_grid=>mc_fc_loc_delete_row TO lt_toolbar_excl.
APPEND cl_gui_alv_grid=>mc_fc_loc_append_row TO lt_toolbar_excl.
APPEND cl_gui_alv_grid=>mc_fc_loc_insert_row TO lt_toolbar_excl.
APPEND cl_gui_alv_grid=>mc_fc_loc_copy_row TO lt_toolbar_excl.
APPEND cl_gui_alv_grid=>mc_fc_loc_undo TO lt_toolbar_excl.
APPEND cl_gui_alv_grid=>mc_fc_check TO lt_toolbar_excl.
APPEND cl_gui_alv_grid=>mc_fc_refresh TO lt_toolbar_excl.
And Pass the lt_toolbar_excl to the ALV object
Display
CALL METHOD go_alv_grid->set_table_for_first_display
EXPORTING
is_variant = ls_variant
is_layout = ls_alv_lay
is_print = ls_print
i_save = 'A'
it_toolbar_excluding = lt_toolbar_excl
CHANGING
it_sort = lt_sort
it_outtab = gt_user[]
it_fieldcatalog = lt_alv_cat.
Hope this helps you.
Thanks,
Ruthra
09-16-2008 4:21 AM
one signle statement will exclude all buttons.
ps_layout-NO_TOOLBAR = 'X'. "this excludes all the buttons
call method g_grid->set_table_for_first_display
exporting is_layout = ps_layout
changing it_fieldcatalog = pt_fieldcat
it_outtab = pt_outtab.
03-23-2009 9:34 PM