2014 Aug 11 9:12 AM
Hi Gurus,
I make an alv with cl_gui_alv_grid I'd like to disable the alv original toolbar and I'd like to add one new button.
How can I do this?
Now I made this:
DATA: lt_toolbar TYPE ttb_button.
class lcl_alv_grid DEFINITION create public INHERITING FROM cl_gui_alv_grid.
PUBLIC SECTION.
methods m1.
endclass.
class lcl_alv_grid IMPLEMENTATION.
method m1.
CALL METHOD SET_TOOLBAR_BUTTONS
EXPORTING
TOOLBAR_TABLE = lt_toolbar.
ENDMETHOD.
endclass.
If I CREATe the local class before my Creat Object cl_gui_custom_container, my toolbar is apering but the alv is not If I create the my object after cl_gui_custom_container the alv grid is showed well but my toolbar is not.
Do you have any idea/ hint?
If you have other way to make button to alv please say this!
Really Thanks,
Mark
2014 Aug 11 9:32 AM
Deactivation of the standard toolbar:
DATA: wa_layout TYPE lvc_s_layo.
wa_layout-no_toolbar = 'X'.
CALL METHOD grid->set_table_for_first_display
EXPORTING
i_structure_name = ...
is_layout = wa_layout
CHANGING
it_outtab = ...
it_fieldcatalog = ...
Add a new button by using event TOOLBAR of class CL_GUI_ALV_GRID (implement a suitable event-handler)
There's no need to use inheritance here.
Hi Gurus,
I make an alv with cl_gui_alv_grid I'd like to disable the alv original toolbar and I'd like to add one new button.
How can I do this?
Now I made this:
DATA: lt_toolbar TYPE ttb_button.
class lcl_alv_grid DEFINITION create public INHERITING FROM cl_gui_alv_grid.
PUBLIC SECTION.
methods m1.
endclass.
class lcl_alv_grid IMPLEMENTATION.
method m1.
CALL METHOD SET_TOOLBAR_BUTTONS
EXPORTING
TOOLBAR_TABLE = lt_toolbar.
ENDMETHOD.
endclass.
If I CREATe the local class before my Creat Object cl_gui_custom_container, my toolbar is apering but the alv is not If I create the my object after cl_gui_custom_container the alv grid is showed well but my toolbar is not.
Do you have any idea/ hint?
If you have other way to make button to alv please say this!
Really Thanks,
Mark
2014 Aug 11 9:32 AM
Deactivation of the standard toolbar:
DATA: wa_layout TYPE lvc_s_layo.
wa_layout-no_toolbar = 'X'.
CALL METHOD grid->set_table_for_first_display
EXPORTING
i_structure_name = ...
is_layout = wa_layout
CHANGING
it_outtab = ...
it_fieldcatalog = ...
Add a new button by using event TOOLBAR of class CL_GUI_ALV_GRID (implement a suitable event-handler)
There's no need to use inheritance here.
2014 Aug 11 11:09 AM
2014 Aug 11 11:19 AM
2014 Aug 11 11:38 AM
2014 Aug 11 11:49 AM